错误信息
Unable to resolve signature of class decorator when called as an expression.
Type '<VC extends VueClass<Vue>>(target: VC) => VC' is missing the following properties from type 'typeof HelloWorld': extend, nextTick, set, delete, and 7 more.
37 | import { Component, Prop, Vue } from 'vue-property-decorator';
38 |
> 39 | @Component
| ^
40 | export default class HelloWorld extends Vue {
41 | @Prop() private msg!: string;
42 | }
复制代码
解决方法
tsconfig.js > compilerOptions > strictFunctionTypes: false