Skip to content

types are broken in editor with type: module #1452

Description

@Mister-Hope

Describe the bug

Install vuepress with pnpm

Link to the blitz that caused the error

https://stackblitz.com/edit/vuepress-theme-hope?file=package.json,docs%2F.vuepress%2Fconfig.ts

Steps to reproduce

See the editor:

image

Expected behavior

Working, everything is fine in a local editor.

image

Parity with Local

Screenshots

image

The vuepress package is a esm package, while the special thing is that it exports other esm package types directly:

And the defineUserConfig is something that @vuepress/cli exports.

Moreover, when I change the exports to vuepress/cli (which is a sub export that re-export @vuepress/cli),

image

image

Platform

  • OS: [e.g. macOS, Windows, Linux]: Windows
  • Browser: [e.g. Chrome, Safari, Firefox]: Chrome
  • Version: [e.g. 91.1]: 125.0

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions