[@vue/compiler-sfc] Unresolvable type: TSConditionalType
Boke-Space opened this issue · comments
Vue version
3.4.27
Link to minimal reproduction
Steps to reproduce
import { ElTable } from "element-plus"
import { ComponentEmit } from "vue-component-type-helpers";
type TableEmits = ComponentEmit
组件引入类型TableEmits成功运行
What is expected?
传入ElTable得到事件的联合类型 type TableEmits = ComponentEmit;
type TableEmits = (event: "select" | "select-all" | "expand-change" | "current-change" | "selection-change" | "cell-mouse-enter" | "cell-mouse-leave" | "cell-contextmenu" | "cell-click" | "cell-dblclick" | ... 7 more ... | "header-dragend", ...args: any[]) => void
What is actually happening?
![屏幕截图 2024-07-16 150222](https://private-user-images.githubusercontent.com/75684838/348975840-52cb30b6-f372-4e50-ade5-2398dbffab9a.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjI1NzY4MDQsIm5iZiI6MTcyMjU3NjUwNCwicGF0aCI6Ii83NTY4NDgzOC8zNDg5NzU4NDAtNTJjYjMwYjYtZjM3Mi00ZTUwLWFkZTUtMjM5OGRiZmZhYjlhLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MDIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODAyVDA1MjgyNFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWI5NGU3MzU5ZTQ3YWRmOGMyZDlkNzJhMWMxMzlhZTk0N2FmNDMwNTRmNjdkMzZjODk1Mzc0MzI4Mjc2MDFiODQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.hacPdJdCl13-JpzWsO_D-7mEbFjvyNqYz880Wet9BzE)
/home/projects/vitejs-vite-wennky/node_modules/.pnpm/vue-component-type-helpers@2.0.26/node_modules/vue-component-type-helpers/index.d.ts
10 | emit: any;
11 | }, ...args: any) => any ? NonNullable : {};
12 | export type ComponentEmit = T extends new (...angs: any) => {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
13 | $emit: infer E;
| ^^^^^^^^^^^^^^^^^^^
14 | } ? NonNullable : {};
| ^^^^^^^^^^^^^^^^^^^^^^^
System Info
No response
Any additional comments?
No response