Node implemented native ES modules behind a feature flag, but it is just awful. They introduced a new file type ".mjs" that gets special handling and has a bunch of arbitrary rules that determines how they can interact with normal node modules. I though I had been following this discussion, but this slipped under my radar for months. For some reason they felt the need to cater to some bizarre dynamic async importing edge cases that no one actually needs.
There are better solutions and NPM developers have implemented one to prove that it just works. It's OK to raise an exception at runtime when a developer tries to do something ridiculous.
1 comment
[ 13.0 ms ] story [ 668 ms ] threadThere are better solutions and NPM developers have implemented one to prove that it just works. It's OK to raise an exception at runtime when a developer tries to do something ridiculous.