Do you want to request a feature or report a bug?
Maybe a bug.
What is the current behavior?
error: bundling failed: Error: Unable to resolve module `@react-native-community/netinfo`
from `.../src/containers/Main.js`: Module `@react-native-community/netinfo` does not exist
in the Haste module map or in these directories: .../node_modules/@react-native-community
Please Note, this this error is not specific to netinfo. I also had the same issue with react-native-extra-dimensions-android.
What is the expected behavior?
Not throw error for already installed packages.
Please provide your exact Metro configuration and mention your Metro, node, yarn/npm version and operating system.
Mac OS High Sierra
node: v10.14.1
npm: 6.5.0
react-native: 0.59.1
metro.config.js
const blacklist = require('metro-config/src/defaults/blacklist');
module.exports = {
resolver: {
blacklistRE: blacklist([/nodejs-assets\/.*/, /android\/.*/, /ios\/.*/, /unity\/.*/])
},
transformer: {
getTransformOptions: async () => ({
transform: {
experimentalImportSupport: false,
inlineRequires: false
}
})
}
};
Following steps did not solve the issue:
node_modules and reinstalled.react-native start --reset-cahce or npm start -- --reset-cachehaste-map* directories from '/tmp`metro-bundler-cache-*Anyone else having the same issue?
I guess this is the reason
npm WARN @react-native-community/[email protected] requires a peer of react-native@>=0.57 <0.59 but none is installed. You must install peer dependencies yourself.
Having this same issue when trying to use apollo-client, very frustrating
same here with serialport https://github.com/node-serialport/node-serialport
: Module stream does not exist in the Haste module map
I guess this is the reason
npm WARN @react-native-community/[email protected] requires a peer of react-native@>=0.57 <0.59 but none is installed. You must install peer dependencies yourself.
Did you actually determine this was the root cause? Were you able to resolve it?
I guess this is the reason
npm WARN @react-native-community/[email protected] requires a peer of react-native@>=0.57 <0.59 but none is installed. You must install peer dependencies yourself.Did you actually determine this was the root cause? Were you able to resolve it?
Unfortunately no. I upgraded the packages to their latest and it works again. Not sure what the issue is.
Also experimenting the issue, i'm using nodejs-websocket and it has dependences from @types/node like net module, and they are already installed but it fails to find it.
Same issue here. Looking for solution
Most helpful comment
I guess this is the reason