{{ message }}
refactor: Output ESM files w/ .mjs when appropriate#950
Merged
rschristian merged 6 commits intomasterfrom Apr 25, 2022
Merged
Conversation
developit
approved these changes
Apr 25, 2022
rschristian
commented
Apr 25, 2022
developit
reviewed
Apr 25, 2022
| : pkg['jsnext:main'] || 'x.esm.js', | ||
| : pkg['jsnext:main'] || pkgTypeModule | ||
| ? 'x.esm.js' | ||
| : 'x.esm.mjs', |
Owner
There was a problem hiding this comment.
I think .m.js and .esm.js were both poor approximations of .mjs, and we should be able to drop the infix.
Suggested change
Collaborator
Author
There was a problem hiding this comment.
Makes sense, though I wonder if that will confuse some.
For users who might not be super familiar with module formats, Microbundle is quite easy to understand given the current names: esm -> x.esm.js, umd -> x.umd.js, etc. esm -> x.mjs might be harder to follow.
Owner
There was a problem hiding this comment.
It's a reasonable thought, yeah. I could go either way on this.
Co-authored-by: Jason Miller <developit@users.noreply.github.com>
rschristian
commented
Apr 25, 2022
developit
reviewed
Apr 25, 2022
Co-authored-by: Jason Miller <developit@users.noreply.github.com>
Merged
donmccurdy
added a commit
to donmccurdy/glTF-Transform
that referenced
this pull request
Jul 10, 2022
donmccurdy
added a commit
to donmccurdy/glTF-Transform
that referenced
this pull request
Jul 10, 2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Per the conversation on Slack, both modern and esm output formats may now create
.mjsfiles when appropriate.