Firebase - setting reset password landing page

Is it possible to configure the reset password landing page in Firebase. I want to localize this page, since my application is not in English. Is there any way to do this?

Thanks in advance.

+7
firebase firebase-authentication
source share
1 answer

You can configure the Reset password at Firebase Console -> Auth -> Email Templates -> Password Reset and change the link in the letter to indicate your page. Note that the <code> placeholder will be replaced with the Reset password code in the URL.

Then on your user page, you can read the Reset password code from the URL and do

 firebase.auth().confirmPasswordReset(code, newPassword) .then(function() { // Success }) .catch(function() { // Invalid code }) 

If you wish, you can first check if the code is valid before displaying the Reset password form with

 firebase.auth().verifyPasswordResetCode(code) .then(function(email) { // Display a "new password" form with the user email address }) .catch(function() { // Invalid code }) 

https://firebase.google.com/docs/reference/js/firebase.auth.Auth#confirmPasswordReset https://firebase.google.com/docs/reference/js/firebase.auth.Auth#verifyPasswordResetCode

+17
source share

All Articles