Hot reloading (fast refresh) not working on iOS/Android
JessicaYeh opened this issue · 6 comments
Describe the bug
In a fresh create-react-native-web-app, I tested fast refresh on both iOS and Android and it seems to not work. The hot reloading does work on the web version, though. I have to manually press 'r' in the Metro Bundler window, or press Refresh from the debug actions in the app. Fast refresh works for another React Native app I have on both iOS and Android (was not created from create-react-native-web-app). I reproduced this on two different MacOS machines.
To Reproduce
npx create-react-native-web-app MyApp
cd MyApp
npm run android (or npm run ios)
wait for app to load, then open up src/App.js and change some text, save the file
observe that no change happens in the app
press 'r' in the Metro Bundler window
observe that the app now has the change
Version Details
$ npx create-react-native-web-app --version
npx: installed 13 in 2.353s
0.15.4
Hi @JessicaYeh
Have you tried clearing cache?
you can run npm run start-clean
it will run the following commands:
rm -rf $TMPDIR/react-* && watchman watch-del-all && npm start -- --reset-cache
@orYoffe Yup I've tried that, no luck :(
Does the fast refresh work on your machine for iOS/Android?
Actually not, looking for a fix
Thank you!! I truly appreciate your help, my team is currently evaluating options for React Native + Web and so far yours seems very promising!
@JessicaYeh thanks for bringing this to my attention.
I just released a fix in 0.15.5
issue was with babel config, when tried to debug the app i saw another error that showed the real issue
Happy hacking and please add another issue if you have any further issues with the package :)
Excellent!! I just tried the new version and fast refresh is indeed working now! That's very interesting how that babel config was the culprit 🤔 Will definitely let you know if I run into any other issues!