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

[BUG] @shopify/hydrogen doesn't appear to be written in CJS #1277

Closed
arlyxiao opened this issue May 16, 2022 · 1 comment
Closed

[BUG] @shopify/hydrogen doesn't appear to be written in CJS #1277

arlyxiao opened this issue May 16, 2022 · 1 comment
Labels
bug Something isn't working

Comments

@arlyxiao
Copy link
Contributor

arlyxiao commented May 16, 2022

Describe the bug

  1. css-modules example doesn't work.
  2. display the errors in console.

@shopify/hydrogen doesn't appear to be written in CJS, but also doesn't appear to be a valid ES module (i.e. it doesn't have "type": "module" or an .mjs extension for the entry point). Please contact the package author to fix.

To Reproduce

  1. Go to 'examples/css-modules'
  2. Run yarn install && yarn dev
  3. Go to 'http://localhost:3000'. The page can't be shown.
  4. See error in console: '@shopify/hydrogen doesn't appear to be written in CJS, but also doesn't appear to be a valid ES module (i.e. it doesn't have "type": "module" or an .mjs extension for the entry point). Please contact the package author to fix.'

Expected behaviour

  1. It shouldn't show the error in console.
  2. Page should be shown correctly.
  • Hydrogen version: latest
  • Node version: v16.13.2
  • Device details
@arlyxiao arlyxiao added the bug Something isn't working label May 16, 2022
@jplhomer
Copy link
Contributor

Duplicate of Shopify/hydrogen#341

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants