Eddy
Eddy

Reputation: 381

Compatible side by side NDK version was not found React Native

I Have created a blank react native app and added webrtc package and now when I install my react native on my phones ,after installation it gets closed automatically and I don't know why app gets closed . The only thing i have noticed in my terminal is that it is saying Compatible side by side NDK version was not found . my Package.json is

{
  "name": "calling_App",
  "version": "0.0.1",
  "private": true,
  "scripts": {
    "android": "react-native run-android",
    "ios": "react-native run-ios",
    "start": "react-native start",
    "test": "jest",
    "lint": "eslint ."
  },
  "dependencies": {
    "react": "16.11.0",
    "react-native": "0.62.2",
    "react-native-webrtc": "^1.75.3"
  },
  "devDependencies": {
    "@babel/core": "^7.9.0",
    "@babel/runtime": "^7.9.2",
    "@react-native-community/eslint-config": "^1.0.0",
    "babel-jest": "^25.3.0",
    "eslint": "^6.8.0",
    "jest": "^25.3.0",
    "metro-react-native-babel-preset": "^0.59.0",
    "react-test-renderer": "16.11.0"
  },
  "jest": {
    "preset": "react-native"
  }
}

Upvotes: 19

Views: 30551

Answers (4)

Willian Dougherty
Willian Dougherty

Reputation: 91

I got stuck a lot in this problem, and I didn't found this basic instruction, so here we go:

  1. First, make sure you have de NKD installed in your machine (Found this in SDK Manager in Android Studio)
  2. Go to your android project folder, and verify if you have a local.properties file, and inside it verify if you have right pointed the SDK Directory and NDK Directory (NDK is commonly installed in your SDK path).

I'll leave an example:

sdk.dir=C\:\\Users\\You\\AppData\\Local\\Android\\Sdk
ndk.dir=C\:\\Users\\You\\AppData\\Local\\Android\\Sdk\\ndk\\{folder_name_ndk_version}

Upvotes: 4

Gabriel Petersson
Gabriel Petersson

Reputation: 10432

I opened the project in Android Studio and ran it once. Now I can run it from vscode as well

Upvotes: 0

Parisa Baastani
Parisa Baastani

Reputation: 1901

Go to File > Project Structure > SDK location and then in the "Android NDK location" part, give your ndk address location, if you don't have it, you can download it.

Upvotes: 5

Atila Levy
Atila Levy

Reputation: 411

Do you have NDK Side-by-Side installed?

Check your SDK Manager in Android Studio. If not, install, restart your workstation and try running the project again.

enter image description here

Upvotes: 31

Related Questions