Make sure you Notice that the scripts will be run only once on the first render from the element. If you should run a JavaScript function afterwards - emit the celebration with the element and listen to it in JavaScript as explained listed here) https://laravel-livewire.com/docs/2.x/inline-scripts