diff --git a/README.md b/README.md index f95b03de..2cc8f056 100644 --- a/README.md +++ b/README.md @@ -40,12 +40,11 @@ RNFirebase aims to replicate the Firebase Web SDK as closely as possible. Becaus * [Firebase Setup](docs/firebase-setup.md) * API * [Authentication](docs/api/authentication.md) + * [Realtime Database](docs/api/database.md) * [Analytics](docs/api/analytics.md) * [Storage](docs/api/storage.md) - * [Realtime Database](docs/api/database.md) - * [ServerValue](docs/api/server-value.md) * [Messaging](docs/api/cloud-messaging.md) - * [Events](docs/api/events.md) + * [Crash](docs/api/crash.md) ## Contributing diff --git a/docs/installation.android.md b/docs/installation.android.md index eb58e15a..efc16b9a 100644 --- a/docs/installation.android.md +++ b/docs/installation.android.md @@ -1,6 +1,6 @@ # Android Installation -The simplest way of installing on Android is to use React Native linker: +The simplest way of installing on Android is to use the react-native link CLI command & rebuild the project: ``` react-native link react-native-firebase @@ -38,24 +38,45 @@ dependencies { } ``` -Add to `AndroidManifest.xml` file -```diff - -+ -+ -+ -+ -+ +Add the project path to `android/settings.gradle`: -+ -+ -+ -+ -+ -``` - -Add to `android/settings.gradle` ``` include ':react-native-firebase' project(':react-native-firebase').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-firebase/android') ``` + +If you plan on using [Firebase Cloud Messaging](https://firebase.google.com/docs/cloud-messaging/), add the following to `android/app/src/main/AndroidManifest.xml`. + +Add permissions: +``` + + + + +``` + +Set app [launch mode](https://inthecheesefactory.com/blog/understand-android-activity-launchmode/en) inside application props: +``` + +``` + +Add messaging service: +``` + + + + + + + + + + + +```