implicitly any type when deploying to vercel
Unanswered
Atlantic salmon posted this in #help-forum
Atlantic salmonOP
See enclosed screenshot. For some reason. I get the error on the right, even though npm run lint is fine and the type is very well defined.
13 Replies
run
npm run build locally and you will get the same errorVscode will be screaming out those errors, you should fix it, before building.
@dumbboy Vscode will be screaming out those errors, you should fix it, before building.
Atlantic salmonOP
As you can see in the screenshot. The type is very well there and I had successfull builds before with this very code in it.
so you can build without errors, but cannot deploy to vercel?
@joulev run `npm run build` locally and you will get the same error
Atlantic salmonOP
You are right, I'll try that again.
The question still remains though: Why is the type implicitly any suddenly in the build, even though VSCode can infer it.
The question still remains though: Why is the type implicitly any suddenly in the build, even though VSCode can infer it.
@dumbboy so you can build without errors, but cannot deploy to vercel?
Atlantic salmonOP
Yes, exactly.
Nah, thats wrong, you shouldnt be able to build also.
Just give the
user type or disable implicit any.Are you using prisma or anything that would generate types for you on the fly?
You probably ran something locally that generated those types that you aren’t running as part of the build step on vercel - I might be wrong though
Atlantic salmonOP
Totally overlooked that but you are absolutely right. @baked
I cannot seem to mark this question as solved.