You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2-35
Original file line number
Diff line number
Diff line change
@@ -306,40 +306,7 @@ We can use an external authentication provider, such as twitter/facebook for aut
306
306
307
307
### OAuth setup with library
308
308
309
-
We'll use the [react-native-oauth](https://github.com/fullstackreact/react-native-oauth) library, which was built along-side [Firestack](https://github.com/fullstackreact/react-native-firestack) specifically to handle authentication through third-party providers.
310
-
311
-
> If you prefer to use another library, make sure you pass through the `oauthToken` and `oauthTokenSecret` provided by your other library to call the `signInWithProvider()` method.
312
-
313
-
Following the instructions on the [react-native-oauth README](https://github.com/fullstackreact/react-native-oauth), we'll need to install it using `npm`:
314
-
315
-
```javascript
316
-
npm install --save react-native-oauth
317
-
```
318
-
319
-
It's important to set up the authentication library fully with our app configuration. Make sure to configure your app [along with this step](https://github.com/fullstackreact/react-native-oauth#handle-deep-linking-loading) otherwise authentication _cannot_ work.
320
-
321
-
Once the app is configured with the instructions, we can call the `oauthManager`'s (or other library's) login method. We'll need to hold on to the `oauthToken` and an `oauthTokenSecret` provided by the provider. Using these values, we can call the `signInWithProvider()` method. The `signInWithProvider()` method accepts three parameters:
322
-
323
-
1. The provider (such as `twitter`, `facebook`, etc) name
324
-
2. The `authToken` value granted by the provider
325
-
3. The `authTokenSecret` value granted by the provider
326
-
327
-
```javascript
328
-
// For instance, using the react-native-oauth library, this process
If you don't want to use [react-native-oauth](https://github.com/fullstackreact/react-native-oauth), you can use other library such as [react-native-facebook-login](https://github.com/magus/react-native-facebook-login).
@@ -465,7 +432,7 @@ Wouldn't it be nice to send analytics about your app usage from your users? Well
465
432
#### logEventWithName()
466
433
467
434
```javascript
468
-
firestack.logEventWithName("launch", {
435
+
firestack.analytics.logEventWithName("launch", {
469
436
'screen':'Main screen'
470
437
})
471
438
.then(res=>console.log('Sent event named launch'))
0 commit comments