The reason node wants .mjs is not a new problem about diff semantics and the meaning of .js. It's about solving a problem Node has.
-
-
Replying to @wycats @bradleymeck
Is there a 0.1% chance that we could solve the plain js vs modules problem without a special extension and without perf penalties?
2 replies 0 retweets 0 likes -
If the grammars didnt collide, probably but this was talked about in Janhttps://github.com/tc39/tc39-notes/blob/master/es7/2017-01/jan-25.md#13iia-proposed-grammar-change-to-es-modules …
1 reply 1 retweet 3 likes -
Replying to @bradleymeck @satya164
Rejecting package.json + "use modules" for standalone files isn't on technical grounds. But that's where we're at.
3 replies 0 retweets 0 likes -
What's the actual reason people don't like .mjs? It seems like a really easy solution to a complicated problem!
2 replies 0 retweets 1 like -
Because there are tons of different things that .js means already *including ES modules* and a new extension is unneeded and not free.
2 replies 1 retweet 6 likes -
If you're using TypeScript does this matter at all? You're still tranpiling. It's a config flag. Is there a greater cost than just renaming?
3 replies 0 retweets 0 likes -
The reason to avoid .mjs is the same reason node itself chose .js initially despite CJS modules != script.
3 replies 1 retweet 1 like -
Presumably because people would complain? Seems harder now that works uses .jsx and .ts, etc?
1 reply 0 retweets 0 likes -
People are complaining ;) not just e
1 reply 0 retweets 1 like
Me*
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.