Crash problem for react-native version 0.71.x
ardasnturk opened this issue · 1 comments
Requirements:
- Review the documentation
- Search for existing issues in: viromedia/viro & ViroCommunity/viro
- Use the latest ViroReact release
Environment
- Development OS: Mac
- Device OS & Version:
- Android OS version: 13.0
- iOS version: 16.x
- Version:
- ViroReact version: 2.23.0
- React Native version : 0.71.8
- Device(s):
- Google Pixel 4 XL
- iPhone 7
- iPhone 13 Pro Max
Description
Because of react-native
and react
updated with Expo 48, we lost viro support in the application. I am looking for new methods to get viro working again. Please help me with this.
When the application was in Expo 45 version, we integrated Viro and managed to run it without any problems.
Since Expo stopped supporting version 45, we updated to version 48. With this update, react-native
and react
were also updated. That's why the application started to crash when I opened the screens using Viro.
I tried different methods but none of them was a perfect solution.
I posted a post on Viro's Discord channel stating that I had the same problem. You can access my post from this link to respond faster.
The application does not show any log for the crash problem. That's why I can't share it here.
I was only able to reach this error on Android.
package.json:
"react-native": "0.71.8",
"react": "18.2.0",
"@viro-community/react-viro": "^2.23.0",
"expo": "~48.0.18",
Problem solved. Viro doesn't officially support react-native
version 0.71.x, but I can say that it works.
Solution for Android:
- first add
jcenter()
to repositories in android/build.gradle. - add the following code to the dependencies section in android/app/build.gradle
implementation project(':gvr_common')
implementation project(':arcore_client')
implementation project(path: ':react_viro')
implementation project(path: ':viro_renderer')
implementation 'com.google.android.exoplayer:exoplayer:2.17.1'
implementation 'com.google.protobuf.nano:protobuf-javanano:3.0.0-alpha-7'
If you are using expo, you can create a production build with npx expo run:android -d --variant Release
.