Skip to content
This repository has been archived by the owner on Nov 16, 2023. It is now read-only.

Not able to use decorators to define a component #35

Closed
ali-mansur opened this issue Feb 10, 2018 · 4 comments
Closed

Not able to use decorators to define a component #35

ali-mansur opened this issue Feb 10, 2018 · 4 comments

Comments

@ali-mansur
Copy link

ali-mansur commented Feb 10, 2018

Was giving a try for https://github.com/Microsoft/TypeScript-Vue-Starter#using-decorators-to-define-a-component

I see error:

TS1238: Unable to resolve signature of class decorator when called as an expression.
Type '<VC extends VueClass<{}>>(target: VC) => VC' is not assignable to type 'typeof HelloDecorator'.
Property 'extend' is missing in type '<VC extends VueClass<{}>>(target: VC) => VC'.

I am using Typescript version: 2.7.1

//Hello.vue
screen shot 2018-02-10 at 2 45 58 pm

// tsconfig.json
screen shot 2018-02-10 at 3 30 03 pm

@pboymt
Copy link

pboymt commented Feb 24, 2018

I had same problem

@hbelitzisap
Copy link

hbelitzisap commented Mar 1, 2018

I also ran into the same error with TypeScript 2.7.1. This works just fine when using TypeScript 2.6.2.

@elevatebart
Copy link

How about importing Vue from vue ?

import Vue from 'vue';

@ghost
Copy link

ghost commented Dec 10, 2018

image
doc

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants