Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

masonfox's avatar

SparkForm not Working in Vue2

Looks like Vue 2 doesn't like the SparkForm.

Property or method "form" is not defined on the instance but referenced during render. 
Make sure to declare reactive data properties in the data option. (found in root instance)

Any help on this?

0 likes
5 replies
ejdelmonico's avatar

@masonfox Did you instantiate a new SparkForm in the data() method of the component? Forms should work fine in Vue2. I haven't had any issues.

nickfetner's avatar

I had this same issue and was able to resolve it. For me it was only having issues on custom child components with SparkForm instances. My issue was the tags were inside of my root component. I moved the template tags out of the root component and it resolved the issue.

Please or to participate in this conversation.