File tree Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Original file line number Diff line number Diff line change @@ -57,6 +57,19 @@ var vm = new Vue({
5757})
5858```
5959
60+ If you need to access properties from the Vue instance, use the function syntax:
61+
62+ ``` js
63+ var vm = new Vue ({
64+ el: ' #demo' ,
65+ firebase : function () {
66+ return {
67+ anArray: db .ref (' url/to/my/collection' )
68+ }
69+ }
70+ })
71+ ```
72+
6073** About the cancelCallback** : This callback is actually an error handler that
6174is called if the read/write doesn't succeed. You can of course also use it with
6275` asObject: false ` and apply it to arrays. The firebase doc states:
@@ -68,7 +81,7 @@ is called if the read/write doesn't succeed. You can of course also use it with
6881
6982``` html
7083<div id =" demo" >
71- <pre >{{ anObject | json }}</pre >
84+ <pre >{{ anObject }}</pre >
7285 <ul >
7386 <li v-for =" item in anArray" >{{ item.text }}</li >
7487 </ul >
You can’t perform that action at this time.
0 commit comments