Twitter sign in
​
​
You need to create a twitter app, on twitter to use this authentication method.
The Firebase Simple Login JavaScript client now returns both the Twitter access token and access token secret in the response payload from Twitter authentication.
You can access each of these via the user object, under the attributes accessToken and accessTokenSecret as shown below:
1
var firebaseRef = new Firebase('https://<MY-FIREBASE-NAME>.firebaseIO.com');
2
var authClient = new FirebaseAuthClient(firebaseRef, function(error, user) {
3
if (user) {
4
var accessToken = user.accessToken,
5
accessTokenSecret = user.accessTokenSecret;
6
}
7
});
8
​
9
...
10
​
11
// Sample jQuery click event.
12
$myButton.on('click', function(event) {
13
authClient.login('twitter');
14
});
Copied!
Last modified 2yr ago
Copy link