I just plugged Drab into a project to test. What I’d like to do first is to replace an AJAX form data submission with a call to drab handler. I’d still want to do client side form validation. is there a good example of such a thing in drab-land? Or are people just getting all the form data in to Elixir side, doing any validation on the server and pushing down the result?
You may have a problem with JS side validation and Drab. This is because Drab steals JS events on its elements. But why to use client-side when you have Drab?
I would do the server side validation. You may do it the classical way, on submit, or maybe on change of each form element? All depends on you.
You may try non web-ish ways to complete it. For example, when doing an update, you may do a database lock on the record, and wait for the user interaction to commit/rollback. See