How to use the react-native-app-auth.onlyAuthorize function in react-native-app-auth

To help you get started, we’ve selected a few react-native-app-auth examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github FormidableLabs / react-native-app-auth / Example / Latest / components / Advanced.js View on Github external
onlyAuthorize = async () => {
    try {
      const authResult = await onlyAuthorize(config);

      this.animateState(
        {
          authResult,
          tokenResult: null
        },
        500
      );

      this.setState({
        authResult,
        tokenResult: null
      });
    } catch (error) {
      Alert.alert('Failed to authorize', error.message);
    }

react-native-app-auth

React Native bridge for AppAuth for supporting any OAuth 2 provider

MIT
Latest version published 21 days ago

Package Health Score

93 / 100
Full package analysis