Update text input dynamic based off other important
I have this form schema
I would like to update the url text input, based off the other input like crafting a url,
localhost:8000/embed?animation=fireworks
5 Replies
But I don't want to use afterStateUpdate on each input is there a better way
That I can just have a function on the url to get the state when it's updated
Could I even link it in with extra attributes and use alpinejs to update it?
Or is afterStateUpdate my best bet?
is this a custom form in a custom request? Or is this part of the panel builder?
But you can either use default() if it's a new form or if it's a form that is prefilled with fill() just get the var from the request and set it in the fill data
It is apart of the panel builder inside a header action, with a modal form?
I have tried that, but I want the text input to update when I change the toggles or the select?
So just use $set(‘field’, ‘value’) in an afterStateUpdated method.
For each one, okay. Thanks. I though there would be an easier way.