jdf2e/nutui-bingo

代码有bug?

fantasyxxj opened this issue · 2 comments

src/packages/utils/create/component.ts:14:13 - error TS2352: Conversion of type '<PropsOptions extends Readonly<ComponentPropsOptions>, Props extends Readonly<ExtractPropTypes>>(_component: { ...; }) => (props: Record<...> & {}) => any' to type '{ <Props extends Record<string, any>, E extends EmitsOptions = {}, EE extends string = string, S extends SlotsType<Record<string, any>> = {}>(setup: (props: Props, ctx: SetupContext<E, S>) => RenderFunction | Promise<...>, options?: (Pick<...> & { ...; }) | undefined): (props: Props & EmitsToProps<...>) => any; <Pro...' may be a mistake because neither type sufficiently overlaps with the other. If this was intentional, convert the expression to 'unknown' first.
Type '(props: Record<string, any> & {}) => any' is not comparable to type 'DefineComponent<any, any, any, any, any, any, any, any, any, PublicProps, Readonly, {} | { [x: string]: any; }, any>'.
Type '(props: Record<string, any> & {}) => any' is not comparable to type 'ComponentPublicInstanceConstructor<any, any, any, any, ComputedOptions, MethodOptions>'.
Type '(props: Record<string, any> & {}) => any' provides no match for the signature 'new (...args: any[]): any'.

14 create: function <
~~~~~~~~~~
15 PropsOptions extends Readonly,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
...
32 return defineComponent(_component as any);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
33 } as typeof defineComponent,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Found 1 error in src/packages/utils/create/component.ts:14