Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AngelKrak/045f96b436790952411e4f1579844029 to your computer and use it in GitHub Desktop.
Save AngelKrak/045f96b436790952411e4f1579844029 to your computer and use it in GitHub Desktop.
error: cannot find symbol UIImplementationProvider - react-native-reanimated

Errors:

  • :react-native-reanimated:compileReleaseJavaWithJavac FAILED
  • cannot find symbol - class ReaUiImplementationProvider extends UIImplementationProvider
  • constructor UIManagerModule.UIManagerModule(ReactApplicationContext,ViewManagerResolver,int) is not applicable

Description:

  Task :react-native-reanimated:compileReleaseJavaWithJavac FAILED
  /node_modules/react-native-reanimated/android/src/main/java/com/swmansion/reanimated/layoutReanimation/ReanimatedUIManager.java:15: error: cannot find symbol
class ReaUiImplementationProvider extends UIImplementationProvider {
                                          ^
  symbol: class UIImplementationProvider
/node_modules/react-native-reanimated/android/src/main/java/com/swmansion/reanimated/layoutReanimation/ReanimatedUIManager.java:17: error: method does not override or implement a method from a supertype
  @Override
  ^
/node_modules/react-native-reanimated/android/src/main/java/com/swmansion/reanimated/layoutReanimation/ReanimatedUIManager.java:38: error: no suitable constructor found for UIManagerModule(ReactApplicationContext,List<ViewManager>,ReaUiImplementationProvider,int)
    super(
    ^
    constructor UIManagerModule.UIManagerModule(ReactApplicationContext,ViewManagerResolver,int) is not applicable
      (actual and formal argument lists differ in length)
    constructor UIManagerModule.UIManagerModule(ReactApplicationContext,List<ViewManager>,int) is not applicable
      (actual and formal argument lists differ in length)

Tasks:

  • Execution failed for task ':react-native-reanimated:compileReleaseJavaWithJavac'.

Instrucciones:

Agregar en el siguiente archivo "/android/build.gradle", en la parte superior de todo, lo siguiente:

def REACT_NATIVE_VERSION = new File(['node', '--print', "JSON.parse(require('fs').readFileSync(require.resolve('react-native/package.json'), 'utf-8')).version"].execute(null, rootDir).text.trim())

Agregar en el siguiente archivo "/android/build.gradle" dentro de "allprojects", lo siguiente:

allprojects {
  configurations.all {
    resolutionStrategy {
      force "com.facebook.react:react-native:" + REACT_NATIVE_VERSION
    }
  }
  ...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment