Error : Failed to load bundle localhost:8081
I have same issue. I tried to install
npm add @babel/runtime
then
It works for me, i hope it helps you.
Sometimes different programs use same ports like 80,8080 or 8081, when I face this problem I set the default port to 8088. And It works perfect.
Try
react-native run-ios --port=8088
If changing port isn't work, try this. This will install the @babel/runtime package to your project.
npm add @babel/runtime
After this re-compile your project.
I hope it works.
Soluton that works:
rm -rf ios/build/; kill $(lsof -t -i:8081)