0
0
iOS Swiftmobile~5 mins

Firebase Authentication in iOS Swift - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is Firebase Authentication used for in mobile apps?
Firebase Authentication helps apps sign in users securely using email/password, phone numbers, or social accounts like Google and Facebook.
Click to reveal answer
beginner
How do you sign in a user with email and password using Firebase in Swift?
Use Auth.auth().signIn(withEmail:password:completion:) method and handle the result in a completion block to check success or error.
Click to reveal answer
intermediate
What is the purpose of the completion handler in Firebase sign-in methods?
It tells you if the sign-in succeeded or failed and provides user info or error details to handle next steps.
Click to reveal answer
beginner
How can you check if a user is already signed in when your app starts?
Check if Auth.auth().currentUser is not nil. If it has a value, a user is signed in.
Click to reveal answer
intermediate
Why is it important to handle errors during Firebase Authentication?
Handling errors helps show clear messages to users, like wrong password or network issues, improving user experience.
Click to reveal answer
Which Firebase method signs in a user with email and password in Swift?
AAuth.loginUser(email:password:)
BAuth.signInUser(email:password:)
CFirebase.signIn(email:password:)
DAuth.auth().signIn(withEmail:password:)
How do you check if a user is currently signed in with Firebase?
AAuth.auth().currentUser != nil
BAuth.isUserSignedIn()
CFirebase.userExists()
DAuth.user != nil
What should you do if Firebase sign-in returns an error?
AIgnore it and continue
BRestart the app automatically
CShow an error message to the user
DDelete the user account
Which of these is NOT a sign-in method supported by Firebase Authentication?
AFingerprint scan without setup
BPhone number
CSocial media accounts
DEmail and password
What does the completion handler in Firebase sign-in methods provide?
AThe user's password
BUser info or error after sign-in attempt
CThe app's version number
DThe device's location
Explain how to sign in a user with email and password using Firebase Authentication in Swift.
Think about the method call and what you do after it completes.
You got /4 concepts.
    Describe how your app can remember if a user is already signed in when it starts.
    Firebase keeps user info between app launches.
    You got /3 concepts.