Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

代码有bug? #18

Open
fantasyxxj opened this issue May 17, 2023 · 2 comments
Open

代码有bug? #18

fantasyxxj opened this issue May 17, 2023 · 2 comments

Comments

@fantasyxxj
Copy link

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

@Zyl2082
Copy link

Zyl2082 commented Oct 9, 2023

我运行也有这个问题,请问你解决了吗

@sparGuan
Copy link

他们在taro里面用了html标签,全是报错的,只有h5能用

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants