Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error calling RCTDeviceEventEmitter.emit in ReactNative

I am begginer in ReactNative ... After install the first project in my Device This error was displayed:

Error calling RCTDeviceEventEmitter.emit

What is the problem ? enter image description here

like image 649
tohidmahmoudvand Avatar asked May 12 '17 08:05

tohidmahmoudvand


2 Answers

From all my research, the solution that worked for me is the following :

When you launch your app by typing react-native run-android, the error appears.

So, reach your directory containing "adb.exe" ( for me it was C:\Users\username\AppData\Local\Android\Sdk\platform-tools\ )

open a terminal from here. And type adb reverse tcp:8081 tcp:8081

Then, by reloading the app on the phone, it should work.

like image 151
Rohan Gala Avatar answered Nov 09 '22 10:11

Rohan Gala


finally, I found the solution and it's working for me now.

if you are using ReactNative in windows you must turn off the firewall then it will work!

like image 2
Mohsen mokhtari Avatar answered Nov 09 '22 10:11

Mohsen mokhtari