I am using firebase for authentication and using plain javascript (not AngularJS or any other framework such as Angular2 or ionic). After successful signing up with google or Facebook, I want to display the user name, use email and user image.
firebase.auth().onAuthStateChanged(function(user) {
if (user) {
// User is signed in.
var displayName = user.displayName;
var email = user.email;
var photoURL = user.photoURL;
} else {
// User is not logged in, redirect to where you need to.
console.log("Logged out");
}
The above is the snippet on the page which should show up after successful sign up.
And I used the following to display the details, but the page showed up just what is written within the tags.
<p class="isLoggedIn">Logged In: {{user_displayName}} ({{user_email}})<p>
Where am I going wrong?
Any kind of help would be greatly appreciated. Thanks.