If you are starting a new project, please consider using our Starter Kit as a basis for your app.
The steps below are for manually installing and linking the library to an existing React Native project. We do not yet support auto-linking.
$ npm install --save @reactvision/react-viro
$ yarn add @reactvision/react-viro
If you're unsure about which file to edit or where to put specified the lines, we have added links to how this is done in our starter-kit repo.
Please note that these examples are a bit old, the code targets an older version of viro before the ReactVision took over the project. They will be updated soon!
» AR
» VR
-
It doesn't work on my iOS simulator!
AR does not work on iOS simulators. If you are getting an error that looks like:
ARWorldTrackingConfiguration setAutoFocusEnabled: unrecognised
that is expected. Sorry!
See running-on-device in the official react-native docs.