{#- Chirp boost layout — stable base for htmx-boost + SSE + view transitions Extend this layout for apps that use: - htmx-boost (AJAX navigation) - SSE live updates with OOB swaps - View Transitions API Structure is correct by default: no transition on #main, nav links get transition via nav_link macro. Override sse_scope block for live updates. Usage: {% extends "chirp/layouts/boost.html" %} {% block content %}
    ...
{% end %} {% block sse_scope %} {% from "chirp/sse.html" import sse_scope %} {{ sse_scope("/events") }} {% end %} Important: sse_scope is OUTSIDE #main so the connection persists across navigations. If placed inside content, it gets replaced and live updates stop. Uses hx-select="#page-content" to extract only the content div from full-page responses. For persistent shells (topbar, sidebar), prefer chirp/layouts/shell.html. -#} {% block title %}Chirp{% end %} {% block head %}{% end %} {% block body_before %}{% end %}
{% block content %}{% end %}
{% block sse_scope %}{% end %} {% block body_after %}{% end %}