Merge branch 'master' of https://github.com/invertase/react-native-firebase into multi-apps
This commit is contained in:
commit
3504715a53
|
@ -10,6 +10,8 @@ Badge notification is well known on the iOS platform, but also supported by diff
|
||||||
This library uses the [ShortcutBadger](https://github.com/leolin310148/ShortcutBadger) library to set the badge number
|
This library uses the [ShortcutBadger](https://github.com/leolin310148/ShortcutBadger) library to set the badge number
|
||||||
also on Android. A list of supported launcher can be found there.
|
also on Android. A list of supported launcher can be found there.
|
||||||
|
|
||||||
|
!> [iOS] Please note: In order for iOS devices to receive Cloud Messages, ensure you [request permissions](http://invertase.io/react-native-firebase/#/modules/cloud-messaging?id=ios-requestpermissions).
|
||||||
|
|
||||||
## API
|
## API
|
||||||
|
|
||||||
### subscribeToTopic(topic: string)
|
### subscribeToTopic(topic: string)
|
||||||
|
|
|
@ -192,3 +192,13 @@ const ref = firebase.database
|
||||||
.child('roomId');
|
.child('roomId');
|
||||||
ref.keepSynced(true);
|
ref.keepSynced(true);
|
||||||
```
|
```
|
||||||
|
|
||||||
|
#### Security rules and offline persistence
|
||||||
|
|
||||||
|
Bear in mind that security rules live on the firebase server and **not in the client**. In other words, when offline, your app knows nothing about your database's security rules. This can lead to unexpected behaviour, which is explained in detail in the following blog post: https://firebase.googleblog.com/2016/11/what-happens-to-database-listeners-when-security-rules-reject-an-update.html
|
||||||
|
|
||||||
|
Some examples of behaviour you may not expect but may encounter are:
|
||||||
|
|
||||||
|
- Values that should not be readable, according to your security rules, are readable if they were created on the same device.
|
||||||
|
- Values are readable even when not authenticated, if they were created on the same device.
|
||||||
|
- Locations are writable even when they should not be, according to your security rules. This is more likely to cause unwanted behaviour when your app is offline, because when it is *online* the SDK will very quickly roll back the write once the server returns a permission error.
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "react-native-firebase",
|
"name": "react-native-firebase",
|
||||||
"version": "2.0.4",
|
"version": "2.0.5",
|
||||||
"author": "Invertase <contact@invertase.io> (http://invertase.io)",
|
"author": "Invertase <contact@invertase.io> (http://invertase.io)",
|
||||||
"description": "A well tested, feature rich Firebase implementation for React Native, supporting iOS & Android. Individual module support for Auth, Database, Messaging, Remote Config, Storage, Admob, Analytics, Crash Reporting, and Performance.",
|
"description": "A well tested, feature rich Firebase implementation for React Native, supporting iOS & Android. Individual module support for Auth, Database, Messaging, Remote Config, Storage, Admob, Analytics, Crash Reporting, and Performance.",
|
||||||
"main": "index",
|
"main": "index",
|
||||||
|
|
Loading…
Reference in New Issue