-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
firebase options modularization done
- Loading branch information
Showing
4 changed files
with
44 additions
and
74 deletions.
There are no files selected for viewing
This file contains 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,10 @@ | ||
import 'package:firebase_core/firebase_core.dart'; | ||
|
||
final FirebaseOptions androidFirebaseOptions = FirebaseOptions( | ||
apiKey: 'AIzaSyBiK-huaMXXmnI4M0LxYNtH5NasP1o1iHQ', | ||
appId: '1:331315801686:android:28c596f9e2e592e17595f7', | ||
messagingSenderId: '331315801686', | ||
projectId: 'guardiancare-a210f', | ||
databaseURL: 'https://guardiancare-a210f-default-rtdb.asia-southeast1.firebasedatabase.app', | ||
storageBucket: 'guardiancare-a210f.appspot.com', | ||
); |
This file contains 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 |
---|---|---|
@@ -1,89 +1,24 @@ | ||
// File generated by FlutterFire CLI. | ||
// ignore_for_file: lines_longer_than_80_chars, avoid_classes_with_only_static_members | ||
import 'package:firebase_core/firebase_core.dart' show FirebaseOptions; | ||
import 'package:flutter/foundation.dart' | ||
show defaultTargetPlatform, kIsWeb, TargetPlatform; | ||
import 'package:firebase_core/firebase_core.dart'; | ||
import 'package:flutter/foundation.dart' show defaultTargetPlatform, kIsWeb, TargetPlatform; | ||
|
||
import 'web_firebase_options.dart' if (dart.library.html) 'web_firebase_options.dart'; | ||
import 'android_firebase_options.dart' if (dart.library.io) 'android_firebase_options.dart'; | ||
import 'ios_firebase_options.dart' if (dart.library.io) 'ios_firebase_options.dart'; | ||
|
||
/// Default [FirebaseOptions] for use with your Firebase apps. | ||
/// | ||
/// Example: | ||
/// ```dart | ||
/// import 'firebase_options.dart'; | ||
/// // ... | ||
/// await Firebase.initializeApp( | ||
/// options: DefaultFirebaseOptions.currentPlatform, | ||
/// ); | ||
/// ``` | ||
class DefaultFirebaseOptions { | ||
static FirebaseOptions get currentPlatform { | ||
if (kIsWeb) { | ||
return web; | ||
return webFirebaseOptions; | ||
} | ||
switch (defaultTargetPlatform) { | ||
case TargetPlatform.android: | ||
return android; | ||
return androidFirebaseOptions; | ||
case TargetPlatform.iOS: | ||
return ios; | ||
case TargetPlatform.macOS: | ||
return macos; | ||
case TargetPlatform.windows: | ||
throw UnsupportedError( | ||
'DefaultFirebaseOptions have not been configured for windows - ' | ||
'you can reconfigure this by running the FlutterFire CLI again.', | ||
); | ||
case TargetPlatform.linux: | ||
throw UnsupportedError( | ||
'DefaultFirebaseOptions have not been configured for linux - ' | ||
'you can reconfigure this by running the FlutterFire CLI again.', | ||
); | ||
return iosFirebaseOptions; | ||
default: | ||
throw UnsupportedError( | ||
'DefaultFirebaseOptions are not supported for this platform.', | ||
); | ||
} | ||
} | ||
|
||
static const FirebaseOptions web = FirebaseOptions( | ||
apiKey: 'AIzaSyBJKvh4ZXb3npq8cL9-mk-kDlSIUO6VppU', | ||
appId: '1:331315801686:web:2a2609fb7d0ec4187595f7', | ||
messagingSenderId: '331315801686', | ||
projectId: 'guardiancare-a210f', | ||
authDomain: 'guardiancare-a210f.firebaseapp.com', | ||
databaseURL: 'https://guardiancare-a210f-default-rtdb.asia-southeast1.firebasedatabase.app', | ||
storageBucket: 'guardiancare-a210f.appspot.com', | ||
measurementId: 'G-HRJ3C6VEXP', | ||
); | ||
|
||
static const FirebaseOptions android = FirebaseOptions( | ||
apiKey: 'AIzaSyBiK-huaMXXmnI4M0LxYNtH5NasP1o1iHQ', | ||
appId: '1:331315801686:android:28c596f9e2e592e17595f7', | ||
messagingSenderId: '331315801686', | ||
projectId: 'guardiancare-a210f', | ||
databaseURL: 'https://guardiancare-a210f-default-rtdb.asia-southeast1.firebasedatabase.app', | ||
storageBucket: 'guardiancare-a210f.appspot.com', | ||
); | ||
|
||
static const FirebaseOptions ios = FirebaseOptions( | ||
apiKey: 'AIzaSyDwCbSP-Qw1bRg5BvVco5x0VqxoBMAtLgs', | ||
appId: '1:331315801686:ios:3e6128afd380d53a7595f7', | ||
messagingSenderId: '331315801686', | ||
projectId: 'guardiancare-a210f', | ||
databaseURL: 'https://guardiancare-a210f-default-rtdb.asia-southeast1.firebasedatabase.app', | ||
storageBucket: 'guardiancare-a210f.appspot.com', | ||
androidClientId: '331315801686-4co8knverqologscscu70sip0c3iqqd3.apps.googleusercontent.com', | ||
iosClientId: '331315801686-4h0llgi3p79eam8n5bt5vhm735plbg7h.apps.googleusercontent.com', | ||
iosBundleId: 'com.guardiancare.guardiancare', | ||
); | ||
|
||
static const FirebaseOptions macos = FirebaseOptions( | ||
apiKey: 'AIzaSyDwCbSP-Qw1bRg5BvVco5x0VqxoBMAtLgs', | ||
appId: '1:331315801686:ios:cef1e3afa0308d3d7595f7', | ||
messagingSenderId: '331315801686', | ||
projectId: 'guardiancare-a210f', | ||
databaseURL: 'https://guardiancare-a210f-default-rtdb.asia-southeast1.firebasedatabase.app', | ||
storageBucket: 'guardiancare-a210f.appspot.com', | ||
androidClientId: '331315801686-4co8knverqologscscu70sip0c3iqqd3.apps.googleusercontent.com', | ||
iosClientId: '331315801686-drnf2arr18matomgvs169374mbk0jgud.apps.googleusercontent.com', | ||
iosBundleId: 'com.guardiancare.guardiancare.RunnerTests', | ||
); | ||
} |
This file contains 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,13 @@ | ||
import 'package:firebase_core/firebase_core.dart'; | ||
|
||
final FirebaseOptions iosFirebaseOptions = FirebaseOptions( | ||
apiKey: 'AIzaSyDwCbSP-Qw1bRg5BvVco5x0VqxoBMAtLgs', | ||
appId: '1:331315801686:ios:3e6128afd380d53a7595f7', | ||
messagingSenderId: '331315801686', | ||
projectId: 'guardiancare-a210f', | ||
databaseURL: 'https://guardiancare-a210f-default-rtdb.asia-southeast1.firebasedatabase.app', | ||
storageBucket: 'guardiancare-a210f.appspot.com', | ||
androidClientId: '331315801686-4co8knverqologscscu70sip0c3iqqd3.apps.googleusercontent.com', | ||
iosClientId: '331315801686-4h0llgi3p79eam8n5bt5vhm735plbg7h.apps.googleusercontent.com', | ||
iosBundleId: 'com.guardiancare.guardiancare', | ||
); |
This file contains 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,12 @@ | ||
import 'package:firebase_core/firebase_core.dart'; | ||
|
||
final FirebaseOptions webFirebaseOptions = FirebaseOptions( | ||
apiKey: 'AIzaSyBJKvh4ZXb3npq8cL9-mk-kDlSIUO6VppU', | ||
appId: '1:331315801686:web:2a2609fb7d0ec4187595f7', | ||
messagingSenderId: '331315801686', | ||
projectId: 'guardiancare-a210f', | ||
authDomain: 'guardiancare-a210f.firebaseapp.com', | ||
databaseURL: 'https://guardiancare-a210f-default-rtdb.asia-southeast1.firebasedatabase.app', | ||
storageBucket: 'guardiancare-a210f.appspot.com', | ||
measurementId: 'G-HRJ3C6VEXP', | ||
); |