tsc-esm-fix

Make Typescript projects compatible with esm/mjs requirements (by antongolub)

Tsc-esm-fix Alternatives

Similar projects and alternatives to tsc-esm-fix

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a better tsc-esm-fix alternative or higher similarity.

tsc-esm-fix reviews and mentions

Posts with mentions or reviews of tsc-esm-fix. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2022-10-09.
  • TypeScript is now officially 10 years old
    6 projects | news.ycombinator.com | 9 Oct 2022
    Probably because it compiles them to a pre-standard ES5-compatible implementation based on good ol' `Foo.prototype`. And since they've already handled them one way, they can't become spec-compliant without breaking backwards compatibility.

    The other place where this shines through particularly egregiously is the support of ESM static import/export. Everybody's build tools been compiling that back down to CJS so hard that Node.js 16+ introduced intentional incompatibilities between CJS and ESM modes just to get people to finally switch to the standards-compliant module system. So you end up in a situation where the library is written in TypeScript with ESM syntax but the only available browser build is a CJS blob which completely defeats the main touted benefit of static imports/exports, namely dead code elimination...

    So you decide what the hell, let's switch TSC to ESM and moduleResolution node16, and end up having to use something like https://github.com/antongolub/tsc-esm-fix because the only allowed fix for TSC doing the wrong thing is at the completely wrong level - https://www.typescriptlang.org/docs/handbook/esm-node.html - if you don't see what's wrong with that, you're one of today's lucky 10000...

  • TS and ts-jest meet “type”: “module”
    3 projects | dev.to | 11 May 2021

Stats

Basic tsc-esm-fix repo stats
2
67
8.2
about 1 month ago
The modern identity platform for B2B SaaS
The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
workos.com