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

Incompatibility with Create React Native App (CRA) without Expo #3364

Open
richardReitz opened this issue Sep 23, 2024 · 2 comments
Open

Incompatibility with Create React Native App (CRA) without Expo #3364

richardReitz opened this issue Sep 23, 2024 · 2 comments

Comments

@richardReitz
Copy link

Hello,

I am facing an issue when trying to use @react-three/fiber in a React Native project created without Expo (using Create React Native App, CRA). The library seems to have a dependency on Expo-specific packages like expo-gl, which makes it difficult to use in a non-Expo environment.

Steps to Reproduce

  1. Create a new React Native project using npx react-native init MyApp.
  2. Install @react-three/fiber using yarn add @react-three/fiber three.
  3. Attempt to use the library in the project.
@DennisSmolek
Copy link
Contributor

Is there a comparable package to expo-gl that lets you use webgl inside a react-native project?

@CodyJasonBennett
Copy link
Member

CodyJasonBennett commented Oct 1, 2024

The library seems to have a dependency on Expo-specific packages like expo-gl, which makes it difficult to use in a non-Expo environment.

What is the expectation here? Have you tried https://r3f.docs.pmnd.rs/getting-started/installation#react-native? Difficulty is not really actionable.

Is there a comparable package to expo-gl that lets you use webgl inside a react-native project?

No, but I have registered react-native-angle for future work on this. It's possible to fork expo-gl and drop expo and deprecated AR features; just that is still tied to OpenGL and will grow divergent with browsers. There's not a maintained Node.js port either.

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

3 participants