Quantcast
Channel: Active questions tagged react-native+ios - Stack Overflow
Viewing all articles
Browse latest Browse all 16552

react-native link error 'Unknown dependency'

$
0
0

I'm following the example to build a small video chat: https://www.agora.io/en/blog/how-to-build-a-react-native-video-calling-app-using-agora

I created a new project via: npx react-native init AwesomeProject

I added the necessary dependencies:

npm install --save react-native-agora
npm install --save react-native-router-flux
npm install --save react-native-vector-icons

The dependencies can be also seen in the package.json

...
  "dependencies": {
    "react": "16.9.0",
    "react-native": "0.61.5",
    "react-native-agora": "^2.9.1-alpha.2",
    "react-native-router-flux": "^4.0.6",
    "react-native-vector-icons": "^6.6.0"
  },
...

When i start the app via npx react-native run-ios the app will start on my Version 10.2.1 (SimulatorApp-880.5 CoreSimulator-587.35)

I get the following error: Invariant Violation: Native module cannot be null. constructor NativeEventEmitter.js

I tried rebuilding it with npm install and the build was successful.

My guess is that i missed linking react to react-native-agora. I tried to link it with react-native link react-native-agora but i get the following error message:

error Unknown dependency. Make sure that the package you are trying to link is already installed in your "node_modules" and present in your "package.json" dependencies.

Thanks in advance.


Viewing all articles
Browse latest Browse all 16552

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>