I am working on an api based on laravel version 5.3.
It's going to be like Telegram api that can respond to various clients that written with android, iOS or web version(angularjs).
One thing that is an Impartible part of that kind of api is realtime operations.
According to the survey that I did there is a signalR library for ASP.NET that makes developing real-time web functionality easy for ASP.NET developers.
SignalR supports Web Sockets, and falls back to other compatible techniques for older browsers like :
Now I wanted to know that for php and specifically Laravel, Is there a tool that is also easy to write realtime apis?
SignalR provides two built-in hub protocols: a text protocol based on JSON and a binary protocol based on MessagePack. MessagePack generally creates smaller messages compared to JSON. Older browsers must support XHR level 2 to provide MessagePack protocol support.
Who uses SignalR? 63 companies reportedly use SignalR in their tech stacks, including ViaVarejo, accuRx, and XYZ Technology.
Laravel offers broadcasting as a feature to send server-side events to clients. As for clients there is a javascript package which can be implemented
You can read it up in the Laravel Docs
Laravel Echo is a JavaScript library that makes it painless to subscribe to channels and listen for events broadcast by Laravel. You may install Echo via the NPM package manager.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With