docs(analytics): update setAnalyticsCollectionEnabled example (#4027)

Co-authored-by: Mike Diarmid <mike.diarmid@gmail.com>
This commit is contained in:
gaodeng
2020-08-03 18:11:49 +08:00
committed by GitHub
parent 07f98bd798
commit 03fe17fada

View File

@@ -140,5 +140,7 @@ on the `firebase.json` file at the root of your project directory.
To re-enable analytics (e.g. once you have the users consent), call the `setAnalyticsCollectionEnabled` method:
```js
import { firebase } from '@react-native-firebase/analytics';
// ...
await firebase.analytics().setAnalyticsCollectionEnabled(true);
```