> &
PP
+type DirectSetupComponent<
+ P extends Record<string, any>,
+ E extends EmitsOptions = {},
+ S extends SlotsType = SlotsType,
+ Props = P & EmitsToProps<E>,
+ PP = PublicProps,
+> = new (
+ props: Props & PP,
+) => CreateComponentPublicInstance<
+ Props,
+ {},
+ {},
+ {},
+ {},
+ ComponentOptionsMixin,
+ ComponentOptionsMixin,
+ E,
+ PP,
+ {},
+ false,
+ {},
+ S
+>
+
// defineComponent is a utility that is primarily used for type inference
// when declaring components. Type inference is provided in the component
// options (provided as the argument). The returned value has artificial types
emits?: E | EE[]
slots?: S
},
-): (props: Props & EmitsToProps<E>) => any
+): DirectSetupComponent<Props, E, S>
export function defineComponent<
Props extends Record<string, any>,
E extends EmitsOptions = {},
emits?: E | EE[]
slots?: S
},
-): (props: Props & EmitsToProps<E>) => any
+): DirectSetupComponent<Props, E, S>
// overload 2: object format with no props
// (uses user defined props interface)