You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
[runtime not ready]: RangeError: Maximum call stack size exceeded (native stack depth)
ERROR [runtime not ready]: Error: Non-js exception: AppRegistryBinding::startSurface failed. Global was not installed.
i am getting this error when using bun isolated installs
@Alvi24 can you help me understand the purpose behind using Bun isolated installs? Your repro is using stackblitz and I believe our stackblitz only covers v4.1 of Nativewind so I can't be sure your project configuration is correct unless you create a repro via npx rn-new@next --nativewind --expo-router
I'm also getting this error, here are some commonalities with your setup:
same exact nativewind / react-native-css versions
also running a monorepo setup with yarn workspaces
I'm getting the error on android, I guess as a runtime error this is more likely..
disabling the globalClassNamePolyfill from react-native-css removes the call stack size error, but introduces others.
My suspicion is that the react-native-css native metro resolution overrides are causing an infinite loop in certain hoisted package scenarios (with Dimensions in this case):
Ok after some more trial and error I have found that installing nativewind, react-native-css at the top level package.json ONLY will get you a working app.
Activity
danstepanov commentedon Oct 13, 2025
@Alvi24 can you help me understand the purpose behind using Bun isolated installs? Your repro is using stackblitz and I believe our stackblitz only covers v4.1 of Nativewind so I can't be sure your project configuration is correct unless you create a repro via
npx rn-new@next --nativewind --expo-routerAlvi24 commentedon Oct 13, 2025
here is a reproductions link: https://github.com/Alvi24/nativewind-fix
danstepanov commentedon Oct 15, 2025
@Alvi24 this repo is called "nativewind-fix", does this mean you have resolved your issue and your repro shows how you've done so?
Alvi24 commentedon Oct 15, 2025
No i haven't resolved the problem, the word "fix" is that "it needs a fix"
Mnigos commentedon Oct 28, 2025
same issue here
huwcarwyn commentedon Dec 12, 2025
I'm also getting this error, here are some commonalities with your setup:
My suspicion is that the react-native-css native metro resolution overrides are causing an infinite loop in certain hoisted package scenarios (with Dimensions in this case):
react-native-css/src/components/index.cts
Line 146 in 008d479
huwcarwyn commentedon Dec 13, 2025
Ok after some more trial and error I have found that installing nativewind, react-native-css at the top level package.json ONLY will get you a working app.
TheMichio commentedon Dec 24, 2025
Hi 👋
@huwcarwyn @Mnigos @Alvi24 @danstepanov
if you're using bun, please add this to your
bunfig.toml, it will resolve the issue:Alvi24 commentedon Mar 27, 2026
so there isn't a way i can use bun isolated installs with natviewind v5?
danstepanov commentedon Apr 15, 2026
Resolved via bunfig.toml configuration as described in the comments. Closing as community-solved.