React-native-auth0: Package android.support.annotation does not exist

Created on 5 Jul 2019  路  7Comments  路  Source: auth0/react-native-auth0

Package android.support.annotation does not exist

_here my code_

react-native-auth0:compileDebugJavaWithJavac FAILED
node_modules\react-native-auth0\android\src\main\java\com\auth0\react\A0Auth0Module.java:9: error: package android.support.annotation does not exist
import android.support.annotation.NonNull;
                                 ^
E:\TestNative\RNChatkitDropbox\node_modules\react-native-auth0\android\src\main\java\com\auth0\react\A0Auth0Module.java:10: error: cannot find symbol
import android.support.customtabs.CustomTabsIntent;
                                 ^
  symbol:   class CustomTabsIntent
  location: package android.support.customtabs
E:\TestNative\RNChatkitDropbox\node_modules\react-native-auth0\android\src\main\java\com\auth0\react\A0Auth0Module.java:121: error: cannot find symbol
    String generateCodeChallenge(@NonNull String codeVerifier) {
                                  ^
  symbol:   class NonNull
  location: class A0Auth0Module
E:\TestNative\RNChatkitDropbox\node_modules\react-native-auth0\android\src\main\java\com\auth0\react\A0Auth0Module.java:61: error: package CustomTabsIntent does not exist
            CustomTabsIntent.Builder builder = new CustomTabsIntent.Builder();
                            ^
E:\TestNative\RNChatkitDropbox\node_modules\react-native-auth0\android\src\main\java\com\auth0\react\A0Auth0Module.java:61: error: package CustomTabsIntent does not exist
            CustomTabsIntent.Builder builder = new CustomTabsIntent.Builder();
                                                                   ^
E:\TestNative\RNChatkitDropbox\node_modules\react-native-auth0\android\src\main\java\com\auth0\react\A0Auth0Module.java:62: error: cannot find symbol
            CustomTabsIntent customTabsIntent = builder.build();
            ^
  symbol:   class CustomTabsIntent
  location: class A0Auth0Module

Most helpful comment

I used this https://www.npmjs.com/package/jetifier with success.

All 7 comments

Same here.

Yes, me too!

Yep, running into the same issue while following the tutorial here: https://auth0.com/docs/quickstart/native/react-native/00-login

I used this https://www.npmjs.com/package/jetifier with success.

Thinking out loud. Can that be related to the react version of your app, or maybe the usage of AndroidX dependencies? Just for the record, this package still doesn't support them.

Yes for me it was related to using react-native 0.60 which uses androidX. Running https://www.npmjs.com/package/jetifier fixes it for me.

I'll close this. Let's keep the conversation on the other issue https://github.com/auth0/react-native-auth0/issues/221

Was this page helpful?
0 / 5 - 0 ratings