Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

sumac_leaves's avatar

Laravel Echo callback when connected using Laravel Reverb

While using Laravel Echo with "socket.io", I had these callbacks defined:

window.Echo.connector.socket.on("connect", () => {
   this.$store.dispatch("connect")
})
window.Echo.connector.socket.on("disconnect", () => {
   this.$store.dispatch("disconnect")
})

Now that I'm using Laravel Reverb, I'm not sure how to do the equivalent. There doesn't appear to be anything in the documentation for a callback that runs when connected.

0 likes
0 replies

Please or to participate in this conversation.