Skip to content

use_channel_layer hook #38

Closed
@Archmonger

Description

@Archmonger

Old Behavior

Currently there is no way of sharing component states across multiple clients.

Proposed Actions

Add in the ability for arbitrary data to be synchronized cross-client.

We will use Django Channels layers to communicate a state across multiple clients. In order to use this feature, the user will need to first configure a Django Channels Layer with a backend such as redis.

The user interface might end up looking like this:

@component
def example():
    sender = use_channel_layers(receiver, channel_name="example", group_name="example")

    return ...

async def receiver(event: dict):
    ...

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions