-
Notifications
You must be signed in to change notification settings - Fork 4k
docs(firebase_analytics): example app initialization and docs support status #7745
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 9 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
6d1b55f
feat: anlytics example app initialization on Android
pr-Mais 8f98a47
docs: add the Dart initialization support status
pr-Mais 9971f10
chore: remove uneeded code
pr-Mais 1ad2f0c
chore: update support status
pr-Mais fb7b76c
docs: note on initialization for google sign in
pr-Mais aa5a883
Update docs/cli.mdx
pr-Mais addc401
Update docs/auth/social.mdx
pr-Mais 7dfcc1a
Update docs/cli.mdx
pr-Mais d49d752
chore: file name typo
pr-Mais 81e8f75
Update docs/cli.mdx
Salakar a34cc44
Update docs/auth/social.mdx
Salakar File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
packages/firebase_analytics/firebase_analytics/example/lib/firebase_config.dart
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import 'dart:developer'; | ||
import 'dart:io'; | ||
|
||
import 'package:firebase_core/firebase_core.dart'; | ||
import 'package:flutter/foundation.dart'; | ||
|
||
class DefaultFirebaseConfig { | ||
static FirebaseOptions? get platformOptions { | ||
if (kIsWeb) { | ||
// Web | ||
return const FirebaseOptions( | ||
apiKey: 'AIzaSyAgUhHU8wSJgO5MVNy95tMT07NEjzMOfz0', | ||
authDomain: 'react-native-firebase-testing.firebaseapp.com', | ||
databaseURL: 'https://react-native-firebase-testing.firebaseio.com', | ||
projectId: 'react-native-firebase-testing', | ||
storageBucket: 'react-native-firebase-testing.appspot.com', | ||
messagingSenderId: '448618578101', | ||
appId: '1:448618578101:web:0b650370bb29e29cac3efc', | ||
measurementId: 'G-F79DJ0VFGS', | ||
); | ||
} else if (Platform.isIOS || Platform.isMacOS) { | ||
// iOS and MacOS | ||
return const FirebaseOptions( | ||
appId: '1:448618578101:ios:cc6c1dc7a65cc83c', | ||
apiKey: 'AIzaSyAHAsf51D0A407EklG1bs-5wA7EbyfNFg0', | ||
projectId: 'react-native-firebase-testing', | ||
messagingSenderId: '448618578101', | ||
iosBundleId: 'com.invertase.testing', | ||
iosClientId: | ||
'448618578101-28tsenal97nceuij1msj7iuqinv48t02.apps.googleusercontent.com', | ||
androidClientId: | ||
'448618578101-a9p7bj5jlakabp22fo3cbkj7nsmag24e.apps.googleusercontent.com', | ||
databaseURL: 'https://react-native-firebase-testing.firebaseio.com', | ||
storageBucket: 'react-native-firebase-testing.appspot.com', | ||
); | ||
} else { | ||
// Android | ||
log("Analytics Dart-only initializer doesn't work on Android, please make sure to add the config file."); | ||
|
||
return null; | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.