Create a "reset" helper that resets all state to the state originally defined in x-data #4566
aaronbushnell
started this conversation in
3. Feature Ideas
Replies: 2 comments 2 replies
-
|
You can use the normal form.reset method, and use the reset data to refeed into the x-data without much issue. 🤔 |
Beta Was this translation helpful? Give feedback.
2 replies
-
|
I posted a solution on StackOverflow. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Sometimes when I have a big form I need a way to "reset" all the form data to what I had originally defined in my
x-datadirective. Something like the following would be really nice!Edit: Modified example to be clearer why
form.reset()doesn't entirely helpBeta Was this translation helpful? Give feedback.
All reactions