Form: TypeScript doesn't know about the Form
function validate
#6980
Labels
Status: Pending Review
Issue or pull request is being reviewed by Core Team
Milestone
Describe the bug
My project relies on server-side validation. I don't know how this is intended to be accomplished with the PrimeVue Forms library. Looking at the documentation, it seems like validation is intended to happen entirely on the client side. That being the case, the way I have accomplished server-side validation feels fairly kludgy. But, setting that aside, the fact remains that I should be able to use
formRef.value.validate();
without TypeScript complaining. As it is now, in Visual Studio Code,validate
is underlined in red and hovering over it shows this:The code works, it's just that it has a TypeScript error that I need to ignore with a
@ts-expect-error
comment.Here is the full code:
Reproducer
https://stackblitz.com/edit/primevue-4-ts-vite-issue-template-csnodp
PrimeVue version
4.2.5
Vue version
3.x
Language
TypeScript
Build / Runtime
Vite
Browser(s)
No response
Steps to reproduce the behavior
No response
Expected behavior
No response
The text was updated successfully, but these errors were encountered: