ktsn / vuex-class

Binding helpers for Vuex and vue-class-component
MIT License
1.73k stars 86 forks source link

[Bug] Webpack warning about missing exported interfaces when used as @Getter type #45

Closed zuoez02 closed 5 years ago

zuoez02 commented 5 years ago

Steps to reproduce

Create new project using vue-cli + TypeScript support Export a TypeScript interface from a file Use the interface in a TypeScript component and decorate with @Getter Build or serve: yarn serve

Version

vue: 2.5.17 vue-class-component: 6.0.0 vue-property-decorator: 7.2.0 vuex-class: 0.3.1 vuex: 3.0.1

I found related issue vue-property-decorator repository https://github.com/kaorun343/vue-property-decorator/issues/122. It seems that they had similar bug and they solved it, now I have met the bug when I'm using @Getter, what should I do.

image

image

ktsn commented 5 years ago

If this is the same issue with https://github.com/kaorun343/vue-property-decorator/issues/122, it's TypeScript bug. See: https://github.com/Microsoft/TypeScript/issues/18008