Skip to content Skip to sidebar Skip to footer

React-native Android Project With Many Error: Could Not Find Class 'android.xxx'

I have a react-native project which should support minimum SDK version of 16 and is androidX but I get these errors using android studio logcat: E/dalvikvm: Could not find class '

Solution 1:

the UserManager is added in SDK version of 17, so it can not find it. you can see this link for details.

if you want to use it, you have to in the android native add support library. the com.android.support:support-compat:28.0.0-alpha1 has it.

if you have added the androidX library, you should change the class to UserManagerCompat. for details, you can go into this link it is located in androidX.core. add the following at android/app/build.gradle

def core_role_version = "1.0.0-alpha01"
implementation "androidx.core:core-role:$core_role_version"

Post a Comment for "React-native Android Project With Many Error: Could Not Find Class 'android.xxx'"