Skip to content

Make sure all the TypeScript types are valid from both CJS and ESM #482

Open
@benjie

Description

@benjie

https://arethetypeswrong.github.io/?p=postgraphile%405.0.0-beta.6

ref https://blog.isquaredsoftware.com/2023/08/esm-modernization-lessons/

CJS default export
CommonJS module simulates a default export with exports.default and exports.__esModule, but does not also set module.exports for compatibility with Node. Node, and some bundlers under certain conditions, do not respect the __esModule marker, so accessing the intended default export will require a .default property access on the default import.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    🐭 Shrew

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions