Is there a way in Filament to calculate a field on the client side without Livewire? AlpineJS?
I have a form as defined here:
The problem with this calculated field
In a non-Filament app I'd solve this by just doing the calculation through AlpineJS and never requiring a live field. However, I'm not sure how I'd do this in the context of a Filament app.
The problem with this calculated field
available_quantity is that the calculation requires the adjustment field to be live which causes debounce issues with the client as seen in the attached GIF. When updating the field that has already sent an ajax request to the server, the client side updates but then reverts if another client side update occurred before getting the ajax response.In a non-Filament app I'd solve this by just doing the calculation through AlpineJS and never requiring a live field. However, I'm not sure how I'd do this in the context of a Filament app.

Solution
Actually what you want is to use AlpineJS to do it for you.. using extraAttributes I suspect? Roughly like: