New <Form> component $form
object type reflection bad in Intelij IDE
#3098
-
I just started messing with the new Following the docs, I applied the attribute I'm using PHPStorm (my back end is PHP) and it generally handles Nuxt / Vue side fairly well (its just a fancier version of WebStorm). The issue I'm having is in the template code PHPStorm is complaining about the use of the The arrows I added show what comes up when I hover the Is there a "type" I can import that would make my IDE stop complaining about this? I really don't like suppressing IDE errors if it can be avoided. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
Unfortunately I do not have the answer. Just to remark that I run into the same issue, of course, in Visual Studio Code. An it is really annoying to look at each form being riddles with red spiral lines. Plus the name of the file, the directory it is in and all the directories above turn red. I know, first world problems but still, really annoying |
Beta Was this translation helpful? Give feedback.
-
Thanks a lot, Rick! That really did the trick |
Beta Was this translation helpful? Give feedback.
OK! Here is my workaround:
Create a folder called
types
(adjacent from yourpages
folder) and place a file namedindex.d.ts
there:Place the following code inside that file:
<Form>
component slots like this:(Basically just add
:PrimevueFormState
to$form
in thev-slot
attr…