Skip to content

why not compiled to pure esm package? #4058

@coader

Description

@coader

after I upgrade vue-tsc from 1.8 to 2.0, type checks failed when build:
error TS1470: The 'import.meta' meta-property is not allowed in files which will build into CommonJS output.

./../node_modules/.pnpm/@types+three@0.161.2/node_modules/@types/three/build/three.d.cts:1:15 - error TS1479: The current file is a CommonJS module whose imports will produce 'require' calls; however, the referenced file is an ECMAScript module and cannot be imported with 'require'. Consider writing a dynamic 'import("../src/Three.js")' call instead.

but I have set type:module in package.json, and it's ok in 1.8.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions