You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This mixin attaches a $fb property on the view model, which has the following API:
API for vm.$fb
.setValue(ref|Firebase)
Creates a new keypath in $data with the .key() of the Firebase ref.
Attaches a listener on the 'value' event and updates the value stored in the keypath.
.setArray(ref|Firebase)
Creates an array with the reference key in $data and attaches listeners
on the Firebase list events(child_added, child_removed, child_moved, child_changed).
.remove(path|String, [ removeLocal|Boolean ])
Removes the Firebase listeners for the given path, so the value stored in $data
is no longer updated.
If removeLocal is set to true, it $deletes the keypath from the view model.
.ref(path|String)
Retrieve the Firebase ref instance previously specified in fb or during a .set* operation.
Note: If the reference is a Firebase Query, .ref(path) will still return the reference to
firebaseUrl/**path** and not the query instance that was passed in.
About
A Vue.js mixin which enables syncing $data of a Vue.js view model with a Firebase reference.