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

Specify "type": "module" when deploying to nodejs-module #4092

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

kawaemon
Copy link
Contributor

@kawaemon kawaemon commented Aug 25, 2024

WIP because this PR depends on #4091

When --target experimental-nodejs-module is specified, Either using .mjs extension or setting "type": "module" field on package.json is required to execute emitted javascript code using Node.js.

In this PR, I used "type": "module" approach because it makes lower impact on existing codebases since it doesn't change file name.

@kawaemon kawaemon changed the title Specify "type": "module" when deploying to nodejs-module Specify "type": "module" when deploying to nodejs-module Aug 25, 2024
@kawaemon kawaemon force-pushed the add-package-json-type-field branch 4 times, most recently from 79ffb04 to 5d97240 Compare September 1, 2024 14:27
@kawaemon kawaemon marked this pull request as ready for review September 1, 2024 14:28
@kawaemon kawaemon force-pushed the add-package-json-type-field branch 2 times, most recently from 64bfbaa to 0228d7c Compare September 1, 2024 15:13
@daxpedda daxpedda added the needs review Needs a review by a maintainer. label Sep 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs review Needs a review by a maintainer.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants