Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

React-native, iOS simulator stops responding to CMD + D

since a couple of months I'm facing a very strange situation, when developing on the latest versions of react native (0.50+ to 0.60+) the iOS simulator stops responding to keyboard commands, that is:

  • Simulator starts, I can hit Cmd+R or Cmd+D just fine for a few cycles
  • After some hot reload cycles, the commands completely stop working
  • If go to Hardware->Keyboard->Send Keyboard Shortcuts and enabled it, the commands start working again
  • However then the Cmd+Shift+H doesn't work anymore so I cannot easily close the app if I have to

This is really driving me crazy, has anybody faced the same situation or knows any workaround? Many thanks!

P.S. I already tried a few months ago to reset everything (including simulator settings and xcode installation)

like image 698
Oscar Franco Avatar asked Jan 14 '20 14:01

Oscar Franco


People also ask

How do you refresh iOS simulator?

Selecting Reload (or pressing ⌘ + r in the iOS simulator) will reload the JavaScript that powers your application.

How do I run react native on specific iOS simulator?

You can specify the device the simulator should run with the --simulator flag, followed by the device name as a string. The default is "iPhone 13" . If you wish to run your app on an iPhone SE (2nd generation), run npx react-native run-ios --simulator='iPhone SE (2nd generation)' .

How to shake iOS simulator?

Hardware > Shake Gesture (Command-Control-Z). This simulates a shake using a motion event but does not simulate other accelerometer actions.

How do I run react native command on iPhone?

Open your react native app's directory, navigate to ios folder, and double-click on . xcworkspace file to open the Xcode. Next, open the Product menu, go to Destination, and select your device. If you don't have an Apple Developer account, you must create one to be able to run your project on an iOS device.


1 Answers

I'm having the same issue. Seems to be an iOS 13.3+ simulator issue as you can see in this thread:

iOS Simulator CMD+R CMD+D Shake doesn't work at all after some time

As an alternative, command + ctrl + z still works to access the development menu.

like image 82
GucaTEC Avatar answered Sep 18 '22 14:09

GucaTEC