React-native-reanimated: Unable to resolve module `./core/AnimatedFunction` from `node_modules/react-native-reanimated/src/base.js`:

Created on 26 Sep 2019  路  14Comments  路  Source: software-mansion/react-native-reanimated

I'm trying to generate a release from my app and got this error:

Loading dependency graph...error Unable to resolve module ./core/AnimatedFunction from node_modules/react-native-reanimated/src/base.js:

None of these files exist:

  • node_modules/react-native-reanimated/src/core/AnimatedFunction(.native|.android.js|.native.js|.js|.android.json|.native.json|.json|.android.ts|.native.ts|.ts|.android.tsx|.native.tsx|.tsx)
  • node_modules/react-native-reanimated/src/core/AnimatedFunction/index(.native|.android.js|.native.js|.js|.android.json|.native.json|.json|.android.ts|.native.ts|.ts|.android.tsx|.native.tsx|.tsx). Run CLI with --verbose flag for more details.
    Error: Unable to resolve module ./core/AnimatedFunction from node_modules/react-native-reanimated/src/base.js:

Any ideas?

Already deleted node_modules and runned npm install again and tried to npm install the library from ground.

Most helpful comment

I checked the version in my node_modules and it's 1.2.0 where the createAnimatedFunction is not present in /react-native-reanimated/src/base.js (This will result Unable to resolve module error). However, createAnimatedFunction is present in version 1.3.0 so I think upgrading the version will fix this.

All 14 comments

I have the same issue when using React Navigation Tabs for React Native App

I checked the version in my node_modules and it's 1.2.0 where the createAnimatedFunction is not present in /react-native-reanimated/src/base.js (This will result Unable to resolve module error). However, createAnimatedFunction is present in version 1.3.0 so I think upgrading the version will fix this.

Thank you @inaki-ibarra

Thank you!! very helpful!!!

I am still experiencing this issue.
bundling failed: Error: Unable to resolve module `react-native-reanimated` from `/Users/username/Documents/Development/projectName/node_modules/react-native-reanimated-slider/src/Slider.js`: Module `react-native-reanimated` does not exist in the Haste module map

Unable to resolve "./core/AnimatedFunction" from "node_modules/react-native-reanimated/src/base.js"

Expo 35: expo installed "react-native-reanimated": "^1.2.0",

With npm installed , same problem

@stevematdavies Have you tried changing the "react-native-reanimated" version to 1.3.0 in package.json?

Yes, but it is then incompatible with some other of my expo managed libraries, and throws more issues

Yes, but it is then incompatible with some other of my expo managed libraries, and throws more issues

the same issue :(

So no fix to this??
This is a potential show stopper for us

Upgrading throws new warning and causes Android Build to fail.

Some of your project's dependencies are not compatible with currently installed expo package version:
 - react-native-reanimated - expected version range: ~1.2.0 - actual version installed: 1.3.0
Your project may not work correctly until you install the correct versions of the packages.
To install the correct versions of these packages, please run: expo install [package-name ...]

still nothing 'bout it ?

So no fix to this??
This is a potential show stopper for us

Upgrading throws new warning and causes Android Build to fail.

Some of your project's dependencies are not compatible with currently installed expo package version:
 - react-native-reanimated - expected version range: ~1.2.0 - actual version installed: 1.3.0
Your project may not work correctly until you install the correct versions of the packages.
To install the correct versions of these packages, please run: expo install [package-name ...]

I had the same problem. Initially using 1.3.0 afterwards reinstall with expo install and get the same error message.
Tried few times and finally expo start -c clear the error

I am getting this issue pls help

error: Error: Unable to resolve module ./animations/TimingAnimation from node_modules\react-native-reanimated\src\Animated.js:

None of these files exist:

  • node_modulesreact-native-reanimated\src\animations\TimingAnimation(.native|.android.js|.native.js|.js|.android.json|.native.json|.json|.android.ts|.native.ts|.ts|.android.tsx|.native.tsx|.tsx)
  • node_modulesreact-native-reanimated\src\animations\TimingAnimation\index(.native|.android.js|.native.js|.js|.android.json|.native.json|.json|.android.ts|.native.ts|.ts|.android.tsx|.native.tsx|.tsx)
    at ModuleResolver.resolveDependency (C:\Users\Gorkem\Desktop\workspace\sns\node_modules\metro\src\node-haste\DependencyGraph\ModuleResolution.js:163:15)
    at ResolutionRequest.resolveDependency (C:\Users\Gorkem\Desktop\workspace\sns\node_modules\metro\src\node-haste\DependencyGraph\ResolutionRequest.js:52:18)
    at DependencyGraph.resolveDependency (C:\Users\Gorkem\Desktop\workspace\sns\node_modules\metro\src\node-haste\DependencyGraph.js:287:16)
    at Object.resolve (C:\Users\Gorkem\Desktop\workspace\sns\node_modules\metro\src\lib\transformHelpers.js:267:42)
    at C:\Users\Gorkem\Desktop\workspace\sns\node_modules\metro\src\DeltaBundler\traverseDependencies.js:434:31
    at Array.map ()
    at resolveDependencies (C:\Users\Gorkem\Desktop\workspace\sns\node_modules\metro\src\DeltaBundler\traverseDependencies.js:431:18)
    at C:\Users\Gorkem\Desktop\workspace\sns\node_modules\metro\src\DeltaBundler\traverseDependencies.js:275:33
    at Generator.next ()
    at asyncGeneratorStep (C:\Users\Gorkem\Desktop\workspace\sns\node_modules\metro\src\DeltaBundler\traverseDependencies.js:87:24)

@grkemtneri, check #1168 out.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jwhscholten picture jwhscholten  路  4Comments

wasim-abuzaher picture wasim-abuzaher  路  3Comments

robertgonzales picture robertgonzales  路  3Comments

bdrobinson picture bdrobinson  路  3Comments

bjartebore picture bjartebore  路  3Comments