Skip to content

Commit d6203f1

Browse files
committed
Prepare for 3.0.0-beta.4
1 parent ccba202 commit d6203f1

File tree

6 files changed

+54
-74
lines changed

6 files changed

+54
-74
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
##### 3.0.0-beta.4 - 01 May 2016
2+
3+
###### Other
4+
- Couple of JSDoc fixes
5+
- Upgraded dependencies
6+
17
##### 3.0.0-beta.3 - 28 April 2016
28

39
###### Breaking changes

fetch/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "js-data-fetch",
33
"description": "HTTP adapter for js-data that uses the fetch API.",
4-
"version": "3.0.0-beta.3",
4+
"version": "3.0.0-beta.4",
55
"homepage": "https://github.com/js-data/js-data-http",
66
"repository": {
77
"type": "git",
@@ -22,6 +22,6 @@
2222
"fetch"
2323
],
2424
"peerDependencies": {
25-
"js-data": "^3.0.0-beta.2"
25+
"js-data": "^3.0.0-beta.3"
2626
}
2727
}

node/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "js-data-http-node",
33
"description": "Node.js HTTP adapter for js-data.",
4-
"version": "3.0.0-beta.3",
4+
"version": "3.0.0-beta.4",
55
"homepage": "https://github.com/js-data/js-data-http",
66
"repository": {
77
"type": "git",
@@ -22,10 +22,10 @@
2222
"node.js"
2323
],
2424
"dependencies": {
25-
"js-data-adapter": "~0.3.0"
25+
"js-data-adapter": "~0.6.1"
2626
},
2727
"peerDependencies": {
2828
"axios": "^0.11.0",
29-
"js-data": "^3.0.0-beta.2"
29+
"js-data": "^3.0.0-beta.3"
3030
}
3131
}

node/webpack.config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
var path= require('path')
1+
var path = require('path')
22

33
module.exports = {
44
devtool: 'source-map',
55
entry: {
6-
'./node/dist/js-data-http-node.js': './src/index.js',
6+
'./node/dist/js-data-http-node.js': './src/index.js'
77
},
88
output: {
99
filename: '[name]',

package.json

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "js-data-http",
33
"description": "HTTP (XHR) adapter for js-data in the browser.",
4-
"version": "3.0.0-beta.3",
4+
"version": "3.0.0-beta.4",
55
"homepage": "https://github.com/js-data/js-data-http",
66
"repository": {
77
"type": "git",
@@ -41,10 +41,14 @@
4141
"after",
4242
"beforeEach",
4343
"afterEach"
44+
],
45+
"ignore": [
46+
"build_examples/",
47+
"dist/"
4448
]
4549
},
4650
"scripts": {
47-
"lint": "repo-tools lint karma.start.js karma.conf.js src/**/*.js test/*.test.js fetch/karma.*.js node/mocha.start.js scripts/*.js",
51+
"lint": "repo-tools lint \"**/*.js\"",
4852
"doc": "jsdoc -c conf.json src node_modules/js-data-adapter/src && node scripts/cleanup.js",
4953
"version": "repo-tools write-version dist/js-data-http.js fetch/dist/js-data-fetch.js node/dist/js-data-http-node.js",
5054
"webpack": "webpack --config webpack.config.js && webpack --config node/webpack.config.js && webpack --config fetch/webpack.config.js && npm run version",
@@ -64,34 +68,27 @@
6468
"ci": "npm test && cat ./coverage/lcov.info | codecov"
6569
},
6670
"dependencies": {
67-
"js-data-adapter": "0.5.0"
71+
"js-data-adapter": "0.6.1"
6872
},
6973
"peerDependencies": {
7074
"js-data": "^3.0.0-beta.3"
7175
},
7276
"devDependencies": {
7377
"axios": "0.11.0",
74-
"babel-core": "6.7.7",
7578
"babel-loader": "6.2.4",
7679
"babel-plugin-syntax-async-functions": "6.5.0",
7780
"babel-plugin-transform-regenerator": "6.6.5",
7881
"babel-polyfill": "6.7.4",
79-
"babel-preset-es2015": "6.6.0",
8082
"babel-preset-stage-0": "6.5.0",
81-
"chai": "3.5.0",
82-
"codecov": "1.0.1",
8383
"istanbul": "0.4.3",
84-
"js-data-repo-tools": "0.3.0",
85-
"jsdoc": "3.4.0",
84+
"js-data-repo-tools": "0.5.0",
8685
"karma": "0.13.22",
8786
"karma-browserstack-launcher": "0.1.11",
8887
"karma-chai": "0.1.0",
8988
"karma-mocha": "0.2.2",
9089
"karma-phantomjs-launcher": "1.0.0",
9190
"karma-sinon": "1.0.4",
92-
"mocha": "2.4.5",
9391
"phantomjs-prebuilt": "2.1.7",
94-
"sinon": "1.17.3",
9592
"source-map-support": "0.4.0",
9693
"uglify-js": "2.6.2",
9794
"webpack": "1.13.0"

src/index.js

Lines changed: 33 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,5 @@
11
/* global fetch:true Headers:true Request:true */
22

3-
/**
4-
* Registered as `js-data-http` in NPM and Bower. The build of `js-data-http`
5-
* that works on Node.js is registered in NPM as `js-data-http-node`. The build
6-
* of `js-data-http` that does not bundle `axios` is registered in NPM and Bower
7-
* as `js-data-fetch`.
8-
*
9-
* __Script tag__:
10-
* ```javascript
11-
* window.HttpAdapter
12-
* ```
13-
* __CommonJS__:
14-
* ```javascript
15-
* var HttpAdapter = require('js-data-http')
16-
* ```
17-
* __ES6 Modules__:
18-
* ```javascript
19-
* import HttpAdapter from 'js-data-http'
20-
* ```
21-
* __AMD__:
22-
* ```javascript
23-
* define('myApp', ['js-data-http'], function (HttpAdapter) { ... })
24-
* ```
25-
*
26-
* @module js-data-http
27-
*/
28-
293
const axios = require('axios')
304
import {utils} from 'js-data'
315
import {
@@ -183,40 +157,16 @@ Object.defineProperty(HttpAdapter, '__super__', {
183157
/**
184158
* Alternative to ES6 class syntax for extending `HttpAdapter`.
185159
*
186-
* __ES6__:
187-
* ```javascript
188-
* class MyHttpAdapter extends HttpAdapter {
189-
* deserialize (Model, data, opts) {
190-
* const data = super.deserialize(Model, data, opts)
191-
* data.foo = 'bar'
192-
* return data
193-
* }
194-
* }
195-
* ```
160+
* @example <caption>Using the ES2015 class syntax.</caption>
161+
* class MyHttpAdapter extends HttpAdapter {...}
162+
* const adapter = new MyHttpAdapter()
196163
*
197-
* __ES5__:
198-
* ```javascript
199-
* var instanceProps = {
200-
* // override deserialize
201-
* deserialize: function (Model, data, opts) {
202-
* var Ctor = this.constructor
203-
* var superDeserialize = (Ctor.__super__ || Object.getPrototypeOf(Ctor)).deserialize
204-
* // call the super deserialize
205-
* var data = superDeserialize(Model, data, opts)
206-
* data.foo = 'bar'
207-
* return data
208-
* },
209-
* say: function () { return 'hi' }
210-
* }
211-
* var classProps = {
212-
* yell: function () { return 'HI' }
213-
* }
164+
* @example <caption>Using {@link HttpAdapter.extend}.</caption>
165+
* var instanceProps = {...}
166+
* var classProps = {...}
214167
*
215168
* var MyHttpAdapter = HttpAdapter.extend(instanceProps, classProps)
216169
* var adapter = new MyHttpAdapter()
217-
* adapter.say() // "hi"
218-
* MyHttpAdapter.yell() // "HI"
219-
* ```
220170
*
221171
* @name HttpAdapter.extend
222172
* @method
@@ -1254,3 +1204,30 @@ exports.addActions = function addActions (opts) {
12541204
* otherwise `false` if the current version is not beta.
12551205
*/
12561206
exports.version = '<%= version %>'
1207+
1208+
/**
1209+
* Registered as `js-data-http` in NPM and Bower. The build of `js-data-http`
1210+
* that works on Node.js is registered in NPM as `js-data-http-node`. The build
1211+
* of `js-data-http` that does not bundle `axios` is registered in NPM and Bower
1212+
* as `js-data-fetch`.
1213+
*
1214+
* __Script tag__:
1215+
* ```javascript
1216+
* window.HttpAdapter
1217+
* ```
1218+
* __CommonJS__:
1219+
* ```javascript
1220+
* var HttpAdapter = require('js-data-http')
1221+
* ```
1222+
* __ES6 Modules__:
1223+
* ```javascript
1224+
* import HttpAdapter from 'js-data-http'
1225+
* ```
1226+
* __AMD__:
1227+
* ```javascript
1228+
* define('myApp', ['js-data-http'], function (HttpAdapter) { ... })
1229+
* ```
1230+
*
1231+
* @module js-data-http
1232+
*/
1233+
exports.default = HttpAdapter

0 commit comments

Comments
 (0)