Unable to resolve module `./../../react-transform-hmr/lib/index.js`

try clear cache using this commend .this method was worked for me

react-native start --reset-cache

This issue only happens when react-native 0.57.2 is installed.

It seems like the Metro Bundler has an issue resolving the paths when started from ./node_modules/react-native/scripts/packager.sh.

Starting the Metro Bundler directly from the project directory works for me. Can someone let me know if it works for them too?

# Clean cache
rm -rf $TMPDIR/react-*; rm -rf $TMPDIR/haste-*; rm -rf $TMPDIR/metro-*; watchman watch-del-all

# Start Metro Bundler directly
react-native start

# Now run `react-native run-android` or `react-native run-ios` in another tab

Source


I got an answer.

Just try:

npm start -- --reset-cache

command, it will work.