antfu / unplugin-vue2-script-setup

💡 Bring `<script setup>` to Vue 2.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

typescript TS7006 TS2339 error

ylucifer opened this issue · comments

generated code:

import { ref } from "@vue/composition-api";
const __sfc_main = {};
// TS7006 TS2339 error
__sfc_main.setup = (__props, __ctx) => {
// ....
};
export default __sfc_main;


expect code:

import { ref } from "@vue/composition-api";
const __sfc_main = {} as any;
__sfc_main.setup = (__props : any, __ctx : any) => {
// ....
};
export default __sfc_main;

I don't know how to config this plugin execute after ts-loader