Skip to content

Commit

Permalink
feat(firebase): add Firebase environment settings
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhiXin18 committed Sep 29, 2024
1 parent 8f20ee0 commit f9610ff
Showing 1 changed file with 69 additions and 0 deletions.
69 changes: 69 additions & 0 deletions lib/firebase_options.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
// 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;

/// 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) {
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for web - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
}
switch (defaultTargetPlatform) {
case TargetPlatform.android:
return android;
case TargetPlatform.iOS:
return ios;
case TargetPlatform.macOS:
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for macos - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
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.',
);
default:
throw UnsupportedError(
'DefaultFirebaseOptions are not supported for this platform.',
);
}
}

static const FirebaseOptions android = FirebaseOptions(
apiKey: 'AIzaSyBO4fMcPW89cI8VTVdpU6R27nLJ_9MkJJs',
appId: '1:210524342027:android:34dc5cb9282a3d0adbc40e',
messagingSenderId: '210524342027',
projectId: 'flowmotion-4e268',
storageBucket: 'flowmotion-4e268.appspot.com',
);

static const FirebaseOptions ios = FirebaseOptions(
apiKey: 'AIzaSyD1qkt7kkgOq8VdazY5aiLXYUFRy5v9NNI',
appId: '1:210524342027:ios:a7c92b2b7ad9b914dbc40e',
messagingSenderId: '210524342027',
projectId: 'flowmotion-4e268',
storageBucket: 'flowmotion-4e268.appspot.com',
///iosClientId: '647805506978-1r33scds0344t919v4ub7jk8bhvrspvf.apps.googleusercontent.com',
iosBundleId: 'com.example.flowmotion',
);
}

0 comments on commit f9610ff

Please sign in to comment.