-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
SyntaxError: Identifier 'module' has already been declared #370
Comments
I can't reproduce this. The code esbuild generates on my end is this: const module2 = __toModule(require("module")); Here's a live link to the code: https://repl.it/@EvanWallace/FlimsyDetailedSequences#index.js |
i created repo with code: |
it's really about the line: "const module = require("module")" - "module" is reserved keyword when it comes to node execution although i find it hard to explain why your repl doesn't have this problem |
The fix was just released in version 0.6.33. |
Simplified version of code that can reproduce this error:
// file.ts
// build.js
node build.js ends up with following error:
I guess "module" is restricted keyword when it comes to cjs format
node v12.18.0
esbuild v0.6.30,
The text was updated successfully, but these errors were encountered: