Answers for "firebase auth change password"

4

how to change user password firebase

var user = firebase.auth().currentUser;
var newPassword = getASecureRandomPassword();

user.updatePassword(newPassword).then(function() {
  // Update successful.
}).catch(function(error) {
  // An error happened.
});
Posted by: Guest on December-06-2020
1

reset password firebase auth

var auth = firebase.auth();
var emailAddress = "[email protected]";
auth.sendPasswordResetEmail(emailAddress)
.then(function() {  
// Email sent.
})
.catch(function(error) {
// An error happened.
});
Posted by: Guest on April-04-2021
2

update photoURL firebase

this.$fireAuth.currentUser.updateProfile({
    displayName: '',
    photoURL: '',
    email: ''
  })
  .then((r) => {
    console.log(r)
  })
  .catch((e) => {
  console.log(e)
})
Posted by: Guest on November-17-2020
0

change password firebase

var user = firebase.auth().currentUser;
 if (user.password == state.password) {
   user.updatePassword(state.password).then(function() {
    // Update successful.
  }).catch(function(error) {
    // An error happened.
  });
 }
Posted by: Guest on July-03-2021

Browse Popular Code Answers by Language