File tree 3 files changed +11
-4
lines changed
3 files changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -18,15 +18,21 @@ Load `js-data-jsonapi-light.js` last.
18
18
import { DataStore } from ' js-data'
19
19
import { JsonApiAdapter } from ' js-data-jsonapi-light'
20
20
21
- // If you don't use import :
21
+ // Or :
22
+ // const store = new JSData.DataStore();
23
+ const store = new DataStore ();
24
+
25
+ // Or :
22
26
// const jsonApiAdapter = new JSDataJsonApiLight.JsonApiAdapter({
23
27
const jsonApiAdapter = new JsonApiAdapter ({
28
+ // Store needs to be given to the adapter
29
+ store: store
30
+
24
31
// Same options as DSHttpAdapter
25
32
// If a serialization option is given, it will be run before JSONApi serialization has occured
26
33
// If a deserialization option is given, it will be run after JSONApi deserialization has occured
27
34
});
28
35
29
- const store = new DataStore ();
30
36
store .registerAdapter (' jsonApi' , jsonApiAdapter, { default: true })
31
37
```
32
38
Original file line number Diff line number Diff line change @@ -49,6 +49,6 @@ module.exports = function (config) {
49
49
browsers : [ 'PhantomJS' ] ,
50
50
singleRun : process . env . NODE_ENV !== 'development' ,
51
51
concurrency : Infinity ,
52
- // client: { captureConsole: process.env.NODE_ENV === 'development' }
52
+ //client: { captureConsole: process.env.NODE_ENV === 'development' }
53
53
} )
54
54
}
Original file line number Diff line number Diff line change 59
59
"dependencies" : {
60
60
"es6-promise" : " ^4.0.5" ,
61
61
"js-data" : " ^3.0.0-rc.7" ,
62
- "js-data-http" : " ^3.0.0-rc.2"
62
+ "js-data-http" : " ^3.0.0-rc.2" ,
63
+ "watchpack" : " 1.2.1"
63
64
}
64
65
}
You can’t perform that action at this time.
0 commit comments