wire:dirty
Last updated
Was this helpful?
Last updated
Was this helpful?
You can use wire:dirty with to display elements when have been updated on the client side but not the server side.
As the user begins typing in the name or email field, CBWIRE will detect the data properties that have changed on the client side and display a reminder to click submit. After the user clicks submit, the data properties are synchronized, and the reminder is removed.
You can invert the behavior of wire:dirty by using the .remove modifier:
You can target specific data properties using wire:dirty and wire:target.
You can toggle classes on elements using wire:dirty.class.
When the user types into the name field, a yellow border is displayed, letting the user know the changes have not been saved.