Kitto.Html.Response
HTML response helper for KittoX. Wraps the existing TKWebResponse to send full HTML pages or HTMX fragments.
TKXWebResponse class
Helper class for sending KittoX HTML responses. Uses a threadvar Current for per-request access.
pascal
class procedure ClearCurrent;Frees and clears the current-thread HTML response.
pascal
procedure SendHTML(const AHTML: string);Sends a full HTML page response (for initial page load).
pascal
procedure SendFragment(const AHTML: string);Sends an HTML fragment response (for HTMX partial updates).
pascal
function IsHtmxRequest: Boolean;Returns True if the current request is an HTMX request (has the HX-Request header).
