#How to prevent '' 'form' implicitly has type 'any' '' warning?

8 messages · Page 1 of 1 (latest)

glacial iron
#

How to prevent this Typescript warning when using form/useForm?

'form' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer.ts(7022)

grim kestrel
#

have you imported useForm?

glacial iron
#

Yup.

grim kestrel
#

okay - do you have any particularly strict custom tsconfig or linter settings?

#

if not - please create a codesandbox that replicates the issue

#

there is a template available in #1006447791498870784 sidebar

glacial iron
#

I don't think it's tsconfig/linter. I just figured out that some of my custom code I added (like another field) and its validation is causing the issue. I will check around that, and if the warning persists, I will write a ticket with code sandbox.

#

Thanks for the help.