{% dj_activity %} — preserved hidden state
React 19 <Activity> parity. Hidden tabs stay alive in the DOM — input, scroll, and focus state survive every show/hide.
Tabs that remember what you typed
{% dj_activity %}Type something in each tab, switch back and forth — your input persists. Compare to typical SPAs where switching tabs unmounts the panel and you lose what you typed.
Profile
Billing
Security
For full {% dj_activity %} behavior — including event-queue throttling so hidden panels stop dispatching events — wrap each panel in the tag. The HTML hidden approach above is a subset that already preserves input state because the elements stay in the DOM.
Currently active: profile. The other panels are still in the DOM (try inspecting!) — that's how their state survives.
The whole pattern
{# Pre-rendered, hidden via the HTML hidden attr —
input state survives every tab switch #}
{% dj_activity "profile" visible=active_tab %}
<input type="text" name="name" placeholder="Your name">
{# Type, switch tabs, switch back — text is still there. #}
{% enddj_activity %}
{% dj_activity "billing" visible=active_tab %}
{# Heavier panel — pre-rendered once, kept warm. #}
{% enddj_activity %}
See docs.djust.org/guides/activity/ for the full guide including eager activities and event-queue caps.