Created
May 2, 2018 12:54
-
-
Save smartITNinja/9902afd4dd69e7c4b082f59214cd2d57 to your computer and use it in GitHub Desktop.
How do I detect if a user is already logged in Firebase?
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
var config = { | |
apiKey: "....", | |
authDomain: "...", | |
databaseURL: "...", | |
projectId: "..", | |
storageBucket: "..", | |
messagingSenderId: ".." | |
}; | |
firebase.initializeApp(config); | |
$( document ).ready(function() { | |
console.log( "testing.." ); | |
var user = firebase.auth().currentUser; | |
console.log(user); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment