Skip to content

declare module '@vue/runtime-core' break the whole app #6503

@yaquawa

Description

@yaquawa

Version

5.0.0-beta.1

Reproduction link

https://github.com/yaquawa/vuetest

Steps to reproduce

Add the following to src/shims-vue.d.ts

declare module '@vue/runtime-core' {
  interface ComponentCustomOptions {
    layout?: string
    breadcrumb?: number
  }
}

then you'll get this:
Screen Shot 2021-05-29 at 18 26 40


I just want to add some custom options for all my components, not sure why this is happening.

If I add the above declare module... to a file of a npm package, for example node_modules/vue-router-layout/lib/index.d.ts, that works..

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