Open aldebout opened 3 months ago
Is there any update on this? I've run into the same issue
now that we have native ws support I do think that we can remove ws
which seems to be the source of the issue.
https://github.com/supabase/realtime-js/pull/426 here's a branch for us to use for testing to see if we can fix it by removing ws from realtime-js dependencies.
but after removing it I keep getting the same issue and the only dependency that uses it's node_modules/@expo/cli
😞 . what could be the way to fix it?
@filipecabaco I'm not sure what the next step is, how can I help you?
@aldebout maybe. it seems that the main issue was the fact that we had the ws
dependency which created issues with expo. the PR https://github.com/supabase/realtime-js/pull/426 removes said dependency.
could you try to checkout the repo, checkout the branch fix/remove-ws-lib
and override the dependency to check if it's not something related to my environment?
I tried using the branch but I'm having issues because package.json
references the build outputs (/dist/...
) and they're not in the github source code :/
When you tested locally, did you use npm with overrides or a local link? I've had issues with npm overrides in the past, it might work better with yarn or pnpm.
I need to try it again but if I'm not mistaken I did use overrides... maybe I should just make an example with just realtime-js and expo to make it easier to test out without overrides and just importing the "fix branch"
Bug report
Describe the bug
When using
@supabase/supabase-js
in an expo react native project, if I use theunstable_enablePackageExports
with the metro bundler, bundling fails with the following error:To Reproduce
@supabase/supabase-js
as a dependency_layout.tsx
filenpx expo customize metro.config.js
config.resolver.unstable_enablePackageExports = true;
tometro.config.js
ios.bundleIdentifier
toapp.json
npx expo run:ios
Repro repo: https://github.com/aldebout/supabase-expo-exports-issue
Expected behavior
No crash
Screenshots
System information
Additional information
Opening here because the error message I got in my actual project was