You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Or create this file in minimal vue-ts (v2) project
import{defineComponent}from"vue";importAppfrom"./App.vue";exportdefaultdefineComponent({// comment next line, and it works fine.components: {App},// or uncomment next line, and it works fine//props: {},data(){return{};},provide(): any{return{fetchData: this.fetchData,};},created(){this.fetchData();},methods: {fetchData(){thrownewError("Not implemented.");},},});
Steps to reproduce
Clone example repo, run pnpm install, run pnpm vue-tsc
What is expected?
No errors.
What is actually happening?
src/broken-method-type.ts:15:23 - error TS2339: Property 'fetchData' does not exist on type 'CreateComponentPublicInstance ...
It works if you remove components: ... line, or add empty props: {}.
(This is continuation of #12628 which is not fixed completely, or happened again, in my project it was working with vue-tsc<1.0, but happened again after update)
The text was updated successfully, but these errors were encountered:
Version
2.7.14
Reproduction link
github.com
Or create this file in minimal vue-ts (v2) project
Steps to reproduce
Clone example repo, run
pnpm install
, runpnpm vue-tsc
What is expected?
No errors.
What is actually happening?
It works if you remove
components: ...
line, or add emptyprops: {}
.(This is continuation of #12628 which is not fixed completely, or happened again, in my project it was working with vue-tsc<1.0, but happened again after update)
The text was updated successfully, but these errors were encountered: