fanout / django-eventstream

Server-Sent Events for Django
MIT License
664 stars 88 forks source link

option to disable json encoding for sse data #79

Closed maikksmt closed 2 years ago

maikksmt commented 3 years ago

to have the option to disable json encoding for sse data an additional argument 'json_encoding' added to send_event( ). It can be used to send raw String data or html String pre-rendered via Django as sse data, so no need to decode json data and /or using additional template engine on client side.

jkarneges commented 3 years ago

Thanks, this seems reasonable. I left a couple of comments.

maikksmt commented 2 years ago

I have added an update based on your review hints.

jkarneges commented 2 years ago

Thanks!