How to use Server Sent Events (SSE) in AdonisJS #4302
-
I need my Adonis API to send SSE events (Server Sent Events) If I was using Express I would use Can I do the same thing in Adonis with response.send()? If not, how do I achieve the same thing? After some experimenting I am wondering if there is something missing in the Adonis Response. In Adonis 4 you could set I see in the code docs for Adonis 5 the following statement for response
But I don't see anyway of actually setting explicitEnd, so I assume response is doomed to always buffer?? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I solved this by using this library https://github.com/afidosstar/adonis-server-sent-events |
Beta Was this translation helpful? Give feedback.
I solved this by using this library https://github.com/afidosstar/adonis-server-sent-events