Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues installing on Windows 10 for RN 0.63.4 + solution #36

Open
ShootingStarDragon opened this issue Feb 20, 2021 · 0 comments
Open

Comments

@ShootingStarDragon
Copy link

Hello, I've been trying to get this package working on the latest react native version and it took me a while so just wanted to leave this info here. The most irritating bug was the app building but instantly crashing on my physical phone with no discernable error.

This is for windows 10, using CLI, and for RN version 0.63.4.

Follow these steps to install properly:

  1. react-native init ProjectName
  2. install react-native-fs using deps
    1. npm install react-native-fs --save --legacy-peer-deps
  3. link -fs (if you run without linking the app will crash)
    1. react-native link react-native-fs
  4. do a test run
    1. npx react-native run-android
    2. <--- the app should run here, working fine as intended
  5. install -opencv3 using deps
    1. npm install react-native-opencv3 --save --legacy-peer-deps
  6. change jetifier to false in \android\gradle.properties
  7. run
    1. npx react-native run-android
    2. builds but on my phone it instantly crashes
  8. If it fails delete the build folder in\android\app\build
  9. now it should work
  10. as a quick test, i included this line in the out of the box app.js right under import React from 'react';
    1. import {CvCamera, CvScalar, Mat, CvInvoke, CvInvokeGroup} from 'react-native-opencv3';
    2. WORKS!

I have yet to see if there are other issues, but I have been able to run the test projects by running git clone -> npm install -> having a 2nd cmd prompt in the same folder and running npx react-native start -> running npx react-native run-android in the 1st cmd prompt. At least I know it works on an older react native version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant