stacks icon indicating copy to clipboard operation
stacks copied to clipboard

Cannot run latest version in expo web

Open rborn opened this issue 3 years ago • 5 comments

👋 I have an issue with the latest expo for web, I get Can't import the named export 'Children' from non EcmaScript module (only default export is available)

I added the plugins: [["react-native-web" /* { commonjs: true } */]] (with or without commonjs) but for some reason it doesn't seem to work.

Steps:

  • upgrade to last expo cli (6.0.6)
  • run expo init ( I chose the tabs template)
  • add babel plugin for expo as per docs
  • try to import Box in any file

Any ideas ? 🙏

rborn avatar Oct 27 '22 09:10 rborn

Small comment, 2.2.1 works well :)

rborn avatar Oct 27 '22 10:10 rborn

@rborn oh no, this bug again 🙈 could you provide a repro repo? I don't use expo on a daily-basis

mobily avatar Nov 14 '22 18:11 mobily

@mobily I will try to add one tomorrow 😍

rborn avatar Nov 14 '22 20:11 rborn

@mobily here you go ❤️ https://github.com/rborn/stacks_expo_issue 🙏

The proper error is

Uncaught TypeError: Cannot read properties of undefined (reading 'get')
    at ./node_modules/@mobily/stacks/dist/esm/index.mjs (index.mjs:553:1)

which leads in the end to Can't import the named export 'Children' from non EcmaScript module (only default export is available)

rborn avatar Nov 15 '22 08:11 rborn

I had the same issue. Version 1.4.1 checks out though. Might be a starting point.

hamedb89 avatar Nov 21 '22 14:11 hamedb89