-
-
Save zontan/3d19c6edeba45f8e55d3d21fbc94d816 to your computer and use it in GitHub Desktop.
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
import FirebaseAuth | |
import FirebaseUI | |
extension MainScreenViewController: FUIAuthDelegate { | |
func showFUIAuthScreen() { | |
let authUI = FUIAuth.defaultAuthUI() | |
authUI?.delegate = self | |
let providers: [FUIAuthProvider] = [ | |
FUIGoogleAuth(), | |
FUIEmailAuth() | |
] | |
authUI?.providers = providers | |
if let authViewController = authUI?.authViewController() { | |
self.present(authViewController, animated: false) | |
} | |
} | |
func authUI(_ authUI: FUIAuth, didSignInWith authDataResult: AuthDataResult?, error: Error?) { | |
//TODO | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment