Skip to content

NiyazNz/django-sse-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Django server sent events (SSE) demo

Demo project for a django SSE feature implementation from github.com/NiyazNz/django.git@serverSentEvent which extends ASGIHandler to handle async data streaming and adds ServerSentEventsResponse.

Examples

See views.py for ServerSentEventsResponse usage examples.

Usage

Install requirements

pip install -r requirements.txt

Start server:

uvicorn sse_demo.asgi:application

Open browser on http://localhost:8000. Open dev tools console/network tab to see messages.

Open http://localhost:8000/message/ in a new tab to send messages.

About

Django server sent events (SSE) demo

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published