Replies: 6 comments 1 reply
-
Commands doesn't support this; however, Commands do work with forms, so you could wire up a command to run on form submit. |
Beta Was this translation helpful? Give feedback.
-
Here's an example from a real world project. Note that this code may produce more questions for you, but at least you can see how it's being used in at least one real world example. |
Beta Was this translation helpful? Give feedback.
-
Are there any plans to add this functionality? Not being able to access form values unless the form is submitted seems like a major downside. For my particular use-case at least. |
Beta Was this translation helpful? Give feedback.
-
Most likely won't be implemented as a feature in the sense that you're thinking. However, you can accomplish what you need in other ways. For example, you can listen for the Though, I don't think we'll ever make collecting all form attributes be implicit behavior in the core library. |
Beta Was this translation helpful? Give feedback.
-
I'd love to see this behaviour added:
and
I'm toying with TBC and trying to see how I could re-implement Invoice Beast with it. Form serialization whenever an action is triggered is needed. |
Beta Was this translation helpful? Give feedback.
-
I agree with the general sentiment, but we want to keep the core library much slimmer than before. Note that Rails provides perfectly sensible form handling out of the box that with the advent of Turbo gained reactivity. Most of the time, a simple Note furthermore that SR‘s |
Beta Was this translation helpful? Give feedback.
-
With Stimulus Reflex, we can send the surrounding form data by setting
serializeForm=true
. Is there an equivalent for TBC? I have buttons triggering commands within a form, and the backend needs to know what the current form values are.Beta Was this translation helpful? Give feedback.
All reactions