Re:Modern Node.js Patterns
by capt_obvious_77 on Monday August 04, 2025 @04:05AM
(#44783164)
Can you elaborate on the compatibility issues you ran into, with ESM, please? Are they related to specific libs or use-cases?
The two I find most annoying
Hoisting/import order especially when trying to mock tests.
Whether or not to include extensions, and which extension to use, .js vs .ts.
Re:Modern Node.js Patterns
by mirkodrummer on Monday August 04, 2025 @06:44AM
(#44784077)
Bun proved both worlds can work together, the mess is all on the Node.js shoulder, and we, the devs, are blamed for not adopting
In many ways, this debacle is reminiscent of the Python 2 to 3 cutover. I wish we had started with bidirectional import interop and dual module publications with graceful transitions instead of this cold turkey "new versions will only publish ESM" approach.