Open afzalursyaref opened 2 years ago
I also tried to push some script to a stack, but without success.
Hi. No update on this issue ?
Actually I just realized that we don't have to push in stack.
This method works very well on my side. Add this to your blade modal
<div>
{{-- Your html--}}
</div>
<script type="text/javascript">
$(document).ready(function () {
// do whatever you want...
window.Livewire.hook('component.initialized', (component) => {})
window.Livewire.hook('element.initialized', (el, component) => {})
window.Livewire.hook('element.updating', (fromEl, toEl, component) => {})
window.Livewire.hook('element.updated', (el, component) => {})
window.Livewire.hook('element.removed', (el, component) => {})
window.Livewire.hook('message.sent', (message, component) => {})
window.Livewire.hook('message.failed', (message, component) => {})
window.Livewire.hook('message.received', (message, component) => {})
window.Livewire.hook('message.processed', (message, component) => {})
});
</script>
i can't push javascript event listener, ex: livewire:load