Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: CJS fallbacks should be at the end not at beginning
- when defining the old CJS `main` and `module`, these properties should come after `exports` (new ESM prop) so that newer NodeJS will try `exports` first (we shouldn't try the fallback first), while for old NodeJS it will automatically use the fallbacks since `exports` won't work, see this TypeScript for more info (https://www.typescriptlang.org/docs/handbook/esm-node.html)
- Loading branch information