Hacker News new | past | comments | ask | show | jobs | submit login

I know it’s a bit of an apples and pears comparison, but which part of changing the file extension feels more difficult than editing package.json?

I’m thinking about new projects rather than converting existing projects.

One benefit I can see to .mjs is that if all extensions are .mjs it’s clear what type of project it is without the need to open up package.json.




With the context you've added now, I might agree. Existing projects would be a pain to rename all files compared to adding a single line to the package.json .

About new projects, I'd have to read more about this new extension, for some reason it feels like a temporary solution that'll just get merged to the normal js extension in a future release.


Yeah it totally has the feel of a temporary solution.

From what I’ve read though, there doesn’t appear to be much of a plan apart from the current solution.

My initial reaction is that I want to keep all my files with .js extension.

One thing that could potentially be problematic is for files that need to run in the browser and on the server.

Really curious to see where the community’s tea leaves settle. My guess is that people will eventually just start using the new extension.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: