I have project on Django wich use Django Channels. I use Django Channel for sending notifications to users who are subscribed to articles changes (adding/editing/deleting comments on article).
What is the way to do it?
Well, that actually depends upon a number of different factors.
In my case, since a person could have multiple tabs open and I want the data to go to all tabs, I use groups.
When a person connects, they connect to a personal group (that user is the only member of that group). If their socket drops and they reconnect, they rejoin that group. If they open multiple tabs, each connection joins the group.
I then send the updates to that group, which is then distributed to all the connections in that group.