Server fragments and dynamic UI
Django and HTMX rendering
The upstream streaming package emits React UI trees. In wdj, application views return trusted Django templates and HTMX swaps them into a stable region. Never execute user-supplied template source or raw generated HTML.
response = render(request, "projects/_list.html", context)response["Cache-Control"] = "no-store"response["Vary"] = "HX-Request"return response
Local behavior after replacement
wdj's delegated handlers survive replacement. Its afterSwap hook initializes the fragment and Alpine state. The playground's Reload action demonstrates this contract.