- On the authentication page we created, we now have the following options:
Figure 12: Adding a Twitter authentication button
- Now let's wire everything up with our JavaScript code, as shown in the following code:
let twitterLogin = document.getElementById('twitterLogin'); twitterLogin.addEventListener('click', () => { //TODO: Add Logic here. });
- Before we move anywhere, we need to configure the twitterProvider object by using the following code line:
var twitterProvider = new firebase.auth.TwitterAuthProvider();
- Now, let's exploit the Firebase authentication API calling with the help of the following code block: ...