viro icon indicating copy to clipboard operation
viro copied to clipboard

When will it support react-native 0.60.+

Open abdallaemadeldin opened this issue 5 years ago • 29 comments

How to make viro react work with react native project where react-native version is 0.61.5? @dthian

abdallaemadeldin avatar Feb 15 '20 13:02 abdallaemadeldin

@abdallaemadeldin, all you need to do is to rebuild Viro with the updated ReactNative version. If the new ReactNative version has new Apis, or function signatures, or dependencies, then you will have to resolve them. Since ViroReact is opensourced, you can pretty much do this upgrade on your local workspace, good luck!

For future Viro questions @VikAdvani would be the best person to ask. Im maintaining mostly the ViroCore repo.

dthian avatar Feb 17 '20 01:02 dthian

@VikAdvani after upgrading package

<ViroVRSceneNavigator
  initialScene={{
          scene: () => {
            return (
               // i added ViroScene here
            );
          }
        }}
      />

app crashed when i add ViroScene do you have any solution?

abdallaemadeldin avatar Feb 17 '20 19:02 abdallaemadeldin

@abdallaemadeldin I'm not sure if you are upgrading the right way. You should just be bumping up the version and then performing a re-install via npm.

However, it looks like Google has released BREAKING changes in their latest version of play services and Firebase because of AndroidX. This is causing havoc in ReactNative. As shown here and here.

I would recommend using Rn 0.59 for now.

dthian avatar Feb 19 '20 04:02 dthian

@dthian thank you so much

abdallaemadeldin avatar Feb 20 '20 08:02 abdallaemadeldin

We're already using Viro with RN 0.60+ on iOS for months now, without any issues.

 "react": "16.9.0",
 "react-native": "0.61.5",
 "react-viro": "^2.17.0",

sercanov avatar Feb 20 '20 11:02 sercanov

@sercanov how did you update it?

abdallaemadeldin avatar Feb 20 '20 16:02 abdallaemadeldin

Interesting, @sercanov did you only test it for iOS? Or did you manage to verify that it works on Android as well with RN 0.60+? (From the links above, it looks like it wouldn't just work right off the bat)

dthian avatar Feb 20 '20 16:02 dthian

For me, the RN version 0.61.5 works on IOS, but on Android, not :(

netojose avatar Feb 23 '20 21:02 netojose

@dthian it's stable on iOS. Last week I managed to made it work on Android with https://github.com/citychallenge/viro

You can try it out on AppStore

sercanov avatar Feb 24 '20 15:02 sercanov

@sercanov could you share the steps with the community on how you got Rn 0.60+ working on Android? From the link you shared, the package.json manifest still had Rn0.59....

dthian avatar Feb 24 '20 15:02 dthian

For iOS, it's pretty straightforward as on the official viro docs, here and here For Android I was getting errors while building, this comment helped https://github.com/viromedia/viro/issues/781#issuecomment-576043790

sercanov avatar Feb 25 '20 08:02 sercanov

And RN 0.62 is coming soon, yet we need to manually build for Android a react_viro-release.aar file each time RN updates. Would be great to build from the project's RN source instead of a hardcoded aar file. I know the goal of the aar file is to reduce the repo size, but it's getting painful.

cristianoccazinsp avatar Mar 05 '20 17:03 cristianoccazinsp

Same issue here. Would need to build react-viro manually with RN 0.60+ since AppStore will not allow new apps that contain RN 59.9 due to deprecations.

sanders54 avatar Mar 19 '20 11:03 sanders54

Upgrading from 59.9 to 62.2 for me was a PITA but it wasn't anything to do with the Viro library that was causing problems, as much as just react-native. Just go into package.json and change the version and reinstall.

There's a number of issues that can pop up at this point, but more than likely they are related to the auto-link issues. Some libs still require manual placement of pods... my build is requiring every pod I need, but it's working in 62.2

Peege151 avatar Apr 20 '20 15:04 Peege151

@sercanov any update on the iOS deprecated UIWebView issue? Apple already stopped receiving the UIWebView API. Now we are unable to upload the app

ManigandanRaamanathan avatar May 03 '20 18:05 ManigandanRaamanathan

@dthian please fix the OS deprecated UIWebView issue

ManigandanRaamanathan avatar May 03 '20 18:05 ManigandanRaamanathan

@ManigandanRaamanathan please stop mass spamming issues that are not related to the UIWebView issue. This thread is related to react upgrades.

dthian avatar May 03 '20 22:05 dthian

Viro currently is dead. Without a way to run it on RN latest version, you will face this issue UIWebView issue and IOs will not accept your app @dthian

emeagenciadigital avatar Jul 21 '20 22:07 emeagenciadigital

Some developers have mitigate this issue @emeagenciadigital, see https://github.com/viromedia/viro/issues/852#issuecomment-657235338. Good luck!

dthian avatar Jul 21 '20 23:07 dthian

I am able to use viro in RN 0.63.3 by doing following:

Clone viro repository Updated react and react-native versions to latest version in package.json Updated react and react-native versions to latest version in package.json in test folder and run npm install (May be not necessary) execute prepare_release.sh in root directory => It generates react-viro-2.17.0.tgz file Created project with react-native init and installed react-viro and create-react-class using npm Remove all the contents of react-viro in node-modules and then extract the contents of tgz file into cleared react-viro. execute this script to make all necessary modifications in gradle, AndroidManifest.xml and java files: ./node_modules/react-viro/bin/android-setup.sh true. Modified few errors Then running android script with GvrDebug, react-native run-android --variant=GvrDebug

The above mentioned steps made my VR app to run perfectly. refer this gist to see all the necessary changes: https://gist.github.com/akeemphilbert/8323a7b71e682469b922920a624b35a8

Hope this helps

akashchekka avatar Oct 21 '20 10:10 akashchekka

I am able to use viro in RN 0.63.3 by doing following:

Clone viro repository Updated react and react-native versions to latest version in package.json Updated react and react-native versions to latest version in package.json in test folder and run npm install (May be not necessary) execute prepare_release.sh in root directory => It generates react-viro-2.17.0.tgz file Created project with react-native init and installed react-viro and create-react-class using npm Remove all the contents of react-viro in node-modules and then extract the contents of tgz file into cleared react-viro. execute this script to make all necessary modifications in gradle, AndroidManifest.xml and java files: ./node_modules/react-viro/bin/android-setup.sh true. Modified few errors Then running android script with GvrDebug, react-native run-android --variant=GvrDebug

The above mentioned steps made my VR app to run perfectly. refer this gist to see all the necessary changes: https://gist.github.com/akeemphilbert/8323a7b71e682469b922920a624b35a8

Hope this helps

Works for me! Thank you.

Would recommend to create a new Repository with the contents of the tgz File and install the Module via "npm install git+..." this will prevent npm to revert the changes on every install

mynameisntrick avatar Oct 26 '20 09:10 mynameisntrick

I am able to use viro in RN 0.63.3 by doing following:

Clone viro repository Updated react and react-native versions to latest version in package.json Updated react and react-native versions to latest version in package.json in test folder and run npm install (May be not necessary) execute prepare_release.sh in root directory => It generates react-viro-2.17.0.tgz file Created project with react-native init and installed react-viro and create-react-class using npm Remove all the contents of react-viro in node-modules and then extract the contents of tgz file into cleared react-viro. execute this script to make all necessary modifications in gradle, AndroidManifest.xml and java files: ./node_modules/react-viro/bin/android-setup.sh true. Modified few errors Then running android script with GvrDebug, react-native run-android --variant=GvrDebug

The above mentioned steps made my VR app to run perfectly. refer this gist to see all the necessary changes: https://gist.github.com/akeemphilbert/8323a7b71e682469b922920a624b35a8

Hope this helps

execute ./prepare_releasae.sh is giving an error of the viro_bridge. can you please tell me about this? @Akash76

haider792 avatar Nov 02 '20 10:11 haider792

@haider792 I'm also with this error. Any idea?

For reference https://github.com/viromedia/viro/issues/917

adelarsq avatar Nov 02 '20 14:11 adelarsq

@mynameisntrick is VR app is on apple store?

haider792 avatar Nov 08 '20 20:11 haider792

Is it planned to make Viro compatible with React Native versions greater than 0.59.9 in the future ?

SamiChab avatar Aug 18 '21 21:08 SamiChab

@SamiChab There is no plans.

On the current project we are maintaining just +0.63.2 versions.

adelarsq avatar Aug 18 '21 22:08 adelarsq

Thank you so much, I didn't knew there was a @viro-community package !!

SamiChab avatar Aug 19 '21 14:08 SamiChab

@SamiChab I decide to create a fork since this project isn't maintained anymore. After a lot of people joined together and we was able to create a community.

See our discord if you need some help. There are already a lot of people there.

By the way we still didn't have time to move the documentation from the original site. It's a little outdated, but still can help.

adelarsq avatar Aug 19 '21 14:08 adelarsq