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

[V4] Unable to resolve "react-native-css-interop" #894

Open
DaveVaval opened this issue Apr 26, 2024 · 7 comments
Open

[V4] Unable to resolve "react-native-css-interop" #894

DaveVaval opened this issue Apr 26, 2024 · 7 comments

Comments

@DaveVaval
Copy link

Describe the bug
When updating to the latest version, or anything passed >4.0.13, I get this issue. After looking at passed issues it seemed like people were experiencing the same thing with pnpm, but in my case I am using NPM.

image

To Reproduce
Steps to reproduce the behavior:

  1. Expo 49.0.93
  2. React Navigation 6
  3. Tailwindcss 3.3.2
  4. Using NPM

Additional context
My bable config:
image

and within my metro config I am requiring withNativeWind :
const { withNativeWind } = require('nativewind/metro');

and returning my config like so:
return withNativeWind(config, { input: './global.css' });

@bradleybernard
Copy link

bradleybernard commented Apr 26, 2024

Also getting the same with, with same looking babel config, but with Expo SDK 51 beta. Only seemed to hit me when I upgraded to SDK 51 beta... hm

iOS Bundling failed 3382ms node_modules/expo-router/entry.js (469 modules)
Unable to resolve "react-native-css-interop/jsx-runtime" from "node_modules/expo-router/build/qualified-entry.js"

@DaveVaval
Copy link
Author

@bradleybernard in your case did it work using expo 50?

@bradleybernard
Copy link

Yep only with 51, I went back down to 50 and it works for some reason. No configs changed, just version changes in package file and lock file

@alxlion
Copy link

alxlion commented May 3, 2024

Forcing to 4.0.1 solved the issue

@DaveVaval
Copy link
Author

Forcing to 4.0.1 solved the issue

Yeah the problem is I can't use the latest version, alot of classes don't work in 4.0.1. It's a bummer but I'll have to put nativewind in standby and stick with stylesheets until a stable release

@GustavoBonfimS
Copy link

I'm using Expo 51 and nativewind@canary (4.0.36) and it's working. The canary release fixed several issues since 4.0.1. See if it works for you.

@younes200
Copy link

When using pnpm, try adding a .npmrc file to address this issue.

node-linker=hoisted
enable-pre-post-scripts=true

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

5 participants