Subscribe on changes!

Generics in defineemits cannot be defined separately from the TS file

avatar
Oct 21st 2021

Version

3.2.20

Reproduction link

codesandbox.io

Steps to reproduce

// h.vue import { XX } from './xx.d.ts'; const emit = defineEmits();

// xx.d.ts export type XX = {(e:'xxx'):void};

What is expected?

--

What is actually happening?

Page operation error


--

avatar
Oct 21st 2021

This is in principle the same issue as #4294

I'll close this as a duplicate.