Skip to content

Commit 88dd299

Browse files
committed
Example update.
1 parent e831e35 commit 88dd299

File tree

3 files changed

+24
-21
lines changed

3 files changed

+24
-21
lines changed

README.md

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ var adapter = new DSFirebaseAdapter({
3535

3636
var store = new JSData.DS();
3737

38-
store.registerAdapter('DSFirebaseAdapter', adapter, { default: true });
38+
store.registerAdapter('firebase', adapter, { default: true });
3939

4040
// "store" will now use the firebase adapter for all async operations
4141
```
@@ -64,21 +64,24 @@ First, feel free to contact me with questions. [Mailing List](https://groups.io/
6464

6565
## License
6666

67+
The MIT License (MIT)
68+
6769
Copyright (c) 2014 Jason Dobry
6870

69-
Permission is hereby granted, free of charge, to any person obtaining a copy of
70-
this software and associated documentation files (the "Software"), to deal in
71-
the Software without restriction, including without limitation the rights to
72-
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
73-
of the Software, and to permit persons to whom the Software is furnished to do
74-
so, subject to the following conditions:
71+
Permission is hereby granted, free of charge, to any person obtaining a copy
72+
of this software and associated documentation files (the "Software"), to deal
73+
in the Software without restriction, including without limitation the rights
74+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
75+
copies of the Software, and to permit persons to whom the Software is
76+
furnished to do so, subject to the following conditions:
7577

7678
The above copyright notice and this permission notice shall be included in all
7779
copies or substantial portions of the Software.
7880

7981
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
80-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
81-
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
82-
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
83-
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
84-
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
82+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
83+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
84+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
85+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
86+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
87+
SOFTWARE.

example/example.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
(function () {
2-
var dsFirebaseAdapter = new DSFirebaseAdapter({
2+
var adapter = new DSFirebaseAdapter({
33
basePath: 'https://js-data-firebase.firebaseio.com'
44
});
55

6-
var datastore = new JSData.DS();
7-
datastore.registerAdapter('DSFirebaseAdapter', dsFirebaseAdapter, { default: true });
6+
var store = new JSData.DS();
7+
store.registerAdapter('firebase', adapter, { default: true });
88

9-
var User = datastore.defineResource('user');
9+
var User = store.defineResource('user');
1010

1111
angular.module('firebase-example', [])
1212
.controller('firebaseCtrl', function ($scope, $timeout) {

example/index.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<script src="https://cdn.firebase.com/js/client/1.0.21/firebase.js"></script>
99
<script src="https://github.com/js-data/js-data/releases/download/0.4.0/js-data-0.4.0.min.js"></script>
1010
<script
11-
src="https://github.com/js-data/js-data-firebase/releases/download/0.4.0/js-data-firebase-0.4.0.min.js"></script>
11+
src="https://github.com/js-data/js-data-firebase/releases/download/0.4.1/js-data-firebase-0.4.1.min.js"></script>
1212
<script src="./example.js"></script>
1313
</head>
1414
<body data-ng-controller="firebaseCtrl as fCtrl">
@@ -43,14 +43,14 @@ <h3 class="panel-title">Users</h3>
4343
</div>
4444
<div>
4545
<pre><code>
46-
var dsFirebaseAdapter = new DSFirebaseAdapter({
46+
var adapter = new DSFirebaseAdapter({
4747
basePath: 'https://js-data-firebase.firebaseio.com'
4848
});
4949

50-
var datastore = new JSData.DS();
51-
datastore.registerAdapter('DSFirebaseAdapter', dsFirebaseAdapter, { default: true });
50+
var store = new JSData.DS();
51+
store.registerAdapter('firebase', adapter, { default: true });
5252

53-
var User = datastore.defineResource('user');
53+
var User = store.defineResource('user');
5454

5555
angular.module('firebase-example', [])
5656
.controller('firebaseCtrl', function ($scope, $timeout) {

0 commit comments

Comments
 (0)