How to update livewire components on record save?

I have two custom Livewire components on my record edit page, and I want them to re-render upon saving. Reloading works. I read about listeners, but I can't find an example.
No description
3 Replies
Dimitar
Dimitar4w ago
Try: https://livewire.laravel.com/docs/events#dispatching-events 1. dispatch event 2. in your custom livewire component sidebar (i suppose) you listen for that event and trigger rerender. Other approach is to not use a custom livewire compoennt, but use a another Section with placeholders and update their value on any filed update and this will make it more "live" and real itme; You can use the $get and $set to chagne states in the sidebar placeholders: https://filamentphp.com/docs/3.x/forms/advanced#generating-a-slug-from-a-title
Laravel
Events | Laravel
A full-stack framework for Laravel that takes the pain out of building dynamic UIs.
Thomas van der Westen
Hmmm thanks! But how to trigger from the form edit page?

Did you find this page helpful?