Skip to content

Instantly share code, notes, and snippets.

@yaizudamashii
Created April 5, 2021 19:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yaizudamashii/ae9ef11997a5c848ade47ae8e04e5d1d to your computer and use it in GitHub Desktop.
Save yaizudamashii/ae9ef11997a5c848ade47ae8e04e5d1d to your computer and use it in GitHub Desktop.
import 'package:firebase_auth/firebase_auth.dart' as FirAuth;
import 'package:flutter_riverpod/flutter_riverpod.dart';
final firebaseAuthProvider = Provider<FirAuth.FirebaseAuth>((ref) => FirAuth.FirebaseAuth.instance);
final authStateChangesProvider = StreamProvider<FirAuth.User>((ref) => ref.watch(firebaseAuthProvider).authStateChanges());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment