Skip to content

Firebase Auth

Import firebase_blocsync_authentication_provider

flutter pub add firebase_blocsync_authentication_provider

Configure Blocsync with Firebase Auth

import 'package:blocsync/blocsync.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:firebase_blocsync_authentication_provider/firebase_blocsync_authentication_provider.dart';
void main() async {
WidgetsFlutterBinding.ensureInitialized();
// Setup Firebase
await Firebase.initializeApp(
options: DefaultFirebaseOptions.currentPlatform,
);
// Configure Blocsync with Firebase Auth
BlocSyncConfig.authProvider = FirebaseAuthProvider();
runApp(MyApp());
}