Skip to content

vue cannot be imported in ESM #4677

@danielroe

Description

@danielroe

Version

3.2.18

Reproduction link

codesandbox.io

Steps to reproduce

After 570c955 we now have a root-level index.mjs. But it's not packaged as it needs to be added to files array.The error is:

Error [ERR_UNSUPPORTED_DIR_IMPORT]: Directory import '/project/node_modules/vue/server-renderer' is not supported resolving ES modules imported from /project/dist/server/server.mjs
Did you mean to import vue/server-renderer/index.js?

Metadata

Metadata

Assignees

No one assigned

    Labels

    ❗ p4-importantPriority 4: this fixes bugs that violate documented behavior, or significantly improves perf.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions