Closed Archmonger closed 7 months ago
There is no convenient method to fetch the Django and ReactPy sessions from within components.
Create a use_session hook.
use_session
This interface could either return a NamedTuple within ReactPy and Django session objects....
NamedTuple
session = use_session() return f"{session.django} {session.reactpy}"
Or, we could use two separate hooks...
django_session = use_django_session() reactpy_session = use_reactpy_session()
Closing this since I currently see no reason anyone would want to access these sessions within a ReactPy component.
If anyone believes otherwise, feel free to comment on this issue and I'll reopen it.
Current Situation
There is no convenient method to fetch the Django and ReactPy sessions from within components.
Proposed Actions
Create a
use_session
hook.This interface could either return a
NamedTuple
within ReactPy and Django session objects....Or, we could use two separate hooks...