Closed Srijans-nd closed 4 years ago
I encountered this error when trying to use the beta as well. Is there a peer dependency that needs to be installed? What's changed?
I've added react-native-unimodules
and metro-config
to my project:
...
"react-native-unimodules": "^0.10.1",
"metro-config": "^0.61.0",
...
and copied the metro.config.js
from here: https://github.com/highcharts/highcharts-react-native/blob/master/metro.config.js
This fixes the problem originally reported here, but the library is still broken:
Error: Unable to resolve module `./http://127.0.0.1:19001/src/index` from ``:
None of these files exist:
* http:/127.0.0.1:19001/src/index(.native|.ios.expo.ts|.native.expo.ts|.expo.ts|.ios.expo.tsx|.native.expo.tsx|.expo.tsx|.ios.expo.js|.native.expo.js|.expo.js|.ios.expo.jsx|.native.expo.jsx|.expo.jsx|.ios.ts|.native.ts|.ts|.ios.tsx|.native.tsx|.tsx|.ios.js|.native.js|.js|.ios.jsx|.native.jsx|.jsx|.ios.json|.native.json|.json|.ios.wasm|.native.wasm|.wasm)
* http:/127.0.0.1:19001/src/index/index(.native|.ios.expo.ts|.native.expo.ts|.expo.ts|.ios.expo.tsx|.native.expo.tsx|.expo.tsx|.ios.expo.js|.native.expo.js|.expo.js|.ios.expo.jsx|.native.expo.jsx|.expo.jsx|.ios.ts|.native.ts|.ts|.ios.tsx|.native.tsx|.tsx|.ios.js|.native.js|.js|.ios.jsx|.native.jsx|.jsx|.ios.json|.native.json|.json|.ios.wasm|.native.wasm|.wasm)
at ModuleResolver.resolveDependency (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:163:15)
at ResolutionRequest.resolveDependency (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/node-haste/DependencyGraph/ResolutionRequest.js:52:18)
at DependencyGraph.resolveDependency (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/node-haste/DependencyGraph.js:287:16)
at /Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/lib/transformHelpers.js:267:42
at Server.<anonymous> (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/Server.js:841:41)
at Generator.next (<anonymous>)
at asyncGeneratorStep (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/Server.js:99:24)
at _next (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/Server.js:119:9)
Error: Unable to resolve module `./index` from ``:
None of these files exist:
* index(.native|.ios.expo.ts|.native.expo.ts|.expo.ts|.ios.expo.tsx|.native.expo.tsx|.expo.tsx|.ios.expo.js|.native.expo.js|.expo.js|.ios.expo.jsx|.native.expo.jsx|.expo.jsx|.ios.ts|.native.ts|.ts|.ios.tsx|.native.tsx|.tsx|.ios.js|.native.js|.js|.ios.jsx|.native.jsx|.jsx|.ios.json|.native.json|.json|.ios.wasm|.native.wasm|.wasm)
* index/index(.native|.ios.expo.ts|.native.expo.ts|.expo.ts|.ios.expo.tsx|.native.expo.tsx|.expo.tsx|.ios.expo.js|.native.expo.js|.expo.js|.ios.expo.jsx|.native.expo.jsx|.expo.jsx|.ios.ts|.native.ts|.ts|.ios.tsx|.native.tsx|.tsx|.ios.js|.native.js|.js|.ios.jsx|.native.jsx|.jsx|.ios.json|.native.json|.json|.ios.wasm|.native.wasm|.wasm)
at ModuleResolver.resolveDependency (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:163:15)
at ResolutionRequest.resolveDependency (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/node-haste/DependencyGraph/ResolutionRequest.js:52:18)
at DependencyGraph.resolveDependency (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/node-haste/DependencyGraph.js:287:16)
at /Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/lib/transformHelpers.js:267:42
at Server.<anonymous> (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/Server.js:841:41)
at Generator.next (<anonymous>)
at asyncGeneratorStep (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/Server.js:99:24)
at _next (/Users/axel/s/pillar/hermes/node_modules/react-native/node_modules/metro/src/Server.js:119:9)
I have tried installing react-native-unimodules, but I got following error after installing
does V3 works fine in expo managedflow or need to convert expo project to bareflow
Hello @Srijans-nd ,
Thank you for reporting the issue.
It is caused by the fact that the dependency react-native-unimodules
is missing in the package.json
of the npm's package, and when installing dependencies, manager does not know that it is required. I will fix it as fast as I can.
Kind regards!
I am still getting this error, was the updated packaged published on npm ?
@sam17896
Have you tried to use the latest v3.1.1 release? Does the problem still exist?
@Denyllon yes the problem still exist for me.. for the record i am not using expo, my problem is created from react-native-cli, is there additional step that i may have to do?
@sam17896 @Lakkanna @axelav Please take a look on this comment: https://github.com/highcharts/highcharts-react-native/issues/91#issuecomment-676261777, follow the steps which you did not do, apply them, and let us know about the result. Would be really appreciated to get some in fo about the result after doing those changes.
Kind regards!
After updating to version 3.0.0, build is failing with below error.
Unable to resolve module
react-native-unimodulesfrom
node_modules/@highcharts/highcharts-react-native/src/HighchartsReactNative.js: react-native-unimodules could not be found within the project.
I was using 2.2.3 before this, and did not face this error. However, I was unable to get chart to render on iOS. I was getting
Error: '@highcharts/highcharts-react-native/highcharts-layout/css/styles.css' cannot be loaded as its extension is not registered in assetExts
Tried approaches mentioned in https://github.com/highcharts/highcharts-react-native/issues/39, so updated to 3.0.0 as per Sebastian's comment.