Skip to content

ESM build is broken (for NodeJS) #2

@Venryx

Description

@Venryx

The ESM build/output is broken, as interpreted by NodeJS: nodejs/node#34515

Basically, NodeJS is not able to recognize the files in ./dist/esm/ as being ESM modules, because the files do not end in .mjs, and the closest package.json file to them does not contain type: module.

My opinion is that NodeJS should infer the files as ESM modules automatically (in this case, based on the module field pointing into the ./dist/esm folder), but the NodeJS devs seem opposed to that idea.

In the meantime, I must keep pestering library developers in the hopes they will appease NodeJS's ESM-import mode rules. 😭

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions