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

require() of ES Module right after init #3738

Open
garrettlove8 opened this issue Apr 4, 2024 · 1 comment
Open

require() of ES Module right after init #3738

garrettlove8 opened this issue Apr 4, 2024 · 1 comment

Comments

@garrettlove8
Copy link

|  Error        Error [ERR_REQUIRE_ESM]: require() of ES Module /Users/username/Development/website/.sst/platform/node_modules/string-width/index.js from /Users/username/Development/website/.sst/platform/node_modules/wide-align/align.js not supported.
|  Instead change the require of index.js in /Users/username/Development/website/.sst/platform/node_modules/wide-align/align.js to a dynamic import() which is available in all CommonJS modules.

I encountered this error trying to run npm run dev --verbose immediately after running sst init. I realize this is a common error to encounter, but my expectation would be that sst init will configure what needs to be configured such that this doesn't happen, or that the docs call it out and direct me to how to fix it.

@ryanleecode
Copy link

Add NO_BUN=true to your env

image

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

2 participants