loading...

re: Tutorial: How to share code between iOS, Android & Web using React Native, react-native-web and monorepo VIEW POST

TOP OF THREAD FULL DISCUSSION
re: After cache clean and everything, second error changed to: error: bundling failed: Error: While trying to resolve module fs from file /Users/..../p...
 

I was running into the same issue and I think I figured out the cause of the problem. I unfortunately don't know how to fix it. It seems to be related to react-native-cli not being able to locate the metro and babel configs because it's being run from the root of the repository.

Since they aren't found, when the bundler comes across react-native-dotenv within a source file it will actually import the source file rather than using the replacement provided by the babel plugin.

Code of Conduct Report abuse