Skip to content

Instantly share code, notes, and snippets.

View techlover1's full-sized avatar

Steven Young techlover1

View GitHub Profile
@jobelenus
jobelenus / websockets-best-practices.md
Last active March 8, 2023 06:52
Websockets with Django - Best Practices

John Obelenus, jobelenus@activefrequency.com

Websockets are basically the same sockets you used in your college programming courses.

Base websocket class

class BaseJsonWebsocketConsumer(JsonWebsocketConsumer):

    def send(self, content, close=False):
        """