Answer the question
In order to leave comments, you need to log in
Why is Broadcasting needed in Laravel?
I can't understand why Broadcasting is needed in Laravel? For example, a chat - after all, I can send all messages to connected clients using js (node.js + socket.io). Why include php and laravel in this process. I must have missed something, I would be grateful for clarification.
For example, I have the task of plotting a graph. How I imagine it. I need to make a request to a third-party api every second and find out the price of a dollar (on js apparently). Having received this data, I write it to the database and simultaneously send it to connected clients via sockets. Here in my logic I use only js.
Question - do I need to look towards Broadcasting in my task, if so, why, am I missing something?
Answer the question
In order to leave comments, you need to log in
If you use laravel echo server, then node.js is still used under the hood. at the expense of Broadcasting, you can use node, which is good, but if you need to transfer a message from the laravel application to the client, what will you do? This is where broadcasting is needed.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question