2 ms·
It's probably going to be a bandaid for a while longer, but the problem is "mixed module loading" and we should fix that problem rather than rely on bandaids lo
by WorldMaker 2y ago
It's probably going to be a bandaid for a while longer, but the problem is "mixed module loading" and we should fix that problem rather than rely on bandaids long term. The last .cjs file I've needed for a while now in type="module" libraries has been for eslint config files and eslint finally supports ESM configs. Everything is just .js, as it should be.
I agree with the article that type="module" should be the default and once it is the well established default the bandaid of .mjs, .cjs, et al extensions should probably provoke a deprecation warning rather than being another long-term tech debt part of Node.