Merge pull request #75 from carllippert/patch-6

Update database.md
This commit is contained in:
Elliot Hesp 2017-04-30 09:01:03 +01:00 committed by GitHub
commit 62660d8de0
1 changed files with 1 additions and 1 deletions

View File

@ -181,7 +181,7 @@ class ToDos extends Component {
#### Differences between `.on` & `.once` #### Differences between `.on` & `.once`
With persistence enabled, any calls to a ref with `.once` will always read the data from disk and not contact the server. With persistence enabled, any calls to a ref with `.once` will always read the data from disk and not contact the server.
On behavious differently, by first checking for a connection and if none exists returns the persisted data. If it successfully connects On behaves differently, by first checking for a connection and if none exists returns the persisted data. If it successfully connects
to the server, the new data will be returned and the disk data will be updated. to the server, the new data will be returned and the disk data will be updated.
The database refs has a `keepSynced()` function to tell the RNFirebase library to keep the data at the `ref` in sync. The database refs has a `keepSynced()` function to tell the RNFirebase library to keep the data at the `ref` in sync.