Exécutez react-native sur l'émulateur android

J'essaie d'exécuter réagir-application native sur android genymotion émulateur sur mon mac.
Quand j'écris react-native run-android Il obtient

Running /usr/local/opt/android-sdk/platform-tools/adb reverse tcp:8081 tcp:8081
error: closed
Could not run adb reverse: Command failed: /usr/local/opt/android-sdk/platform-tools/adb reverse tcp:8081 tcp:8081
Building and installing the app on the device (cd android && ./gradlew installDebug...
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/android-setup.html
MacBook-Pro-MacBook:ART-CarefulPeople macbook$ 

Alors j'ai essayé:

  1. react-native start
  2. react-native run-android

Le même résultat.

Alors j'ai essayé:

  1. react-native bundle --entry-file index.android.js --platform android --bundle-output android/app/src/main/assets/index.android.bundle
  2. curl "http://localhost:8081/index.android.bundle?platform=android" -o "android/app/src/main/assets/index.android.bundle"
  3. react-native run-android

Le même résultat.

J'ai essayé à peu adb reverse tcp:8081 tcp:8081 et il dit error: closed

Quand j'essaye d'exécuter l'application sur android-sdk émulateur, on obtient le même message d'erreur ci-dessus, mais sans error: closed.

À partir d'android studio, je peux exécuter cette application et il fonctionne sur genymotion.
Dites-moi s'il vous plait que dois-je faire pour faire fonctionner mon application sur l'émulateur android?

source d'informationauteur alborozd