Documentation
¶
Overview ¶
Copyright (c) 2024 Eli Janssen Use of this source code is governed by an MIT-style license that can be found in the LICENSE file.
Index ¶
Constants ¶
View Source
const ( // indicates that the request is via an element using hx-boost HxBoosted = "HX-Boosted" // the current URL of the browser HxCurrentURL = "HX-Current-URL" // true if the request is for history restoration after a miss in the local // history cache HxHistoryRestoreRequest = "HX-History-Restore-Request" // the user response to an hx-prompt HxPrompt = "HX-Prompt" // always true if an htmx request HxRequest = "HX-Request" // the id of the target element if it exists HxTarget = "HX-Target" // the name of the triggered element if it exists HxTriggerName = "HX-Trigger-Name" // the id of the triggered element if it exists HxTrigger = "HX-Trigger" // allows you to do a client-side redirect that does not do a full page reload HxLocation = "HX-Location" // pushes a new url into the history stack HxPushUrl = "HX-Push-Url" // can be used to do a client-side redirect to a new location HxRedirect = "HX-Redirect" // if set to “true” the client-side will do a full refresh of the page HxRefresh = "HX-Refresh" // replaces the current URL in the location bar HxReplaceUrl = "HX-Replace-Url" // allows you to specify how the response will be swapped. See hx-swap for possible values HxReswap = "HX-Reswap" // a CSS selector that updates the target of the content update to a different element on the page HxRetarget = "HX-Retarget" // a CSS selector that allows you to choose which part of the response is used to be swapped in. Overrides an existing hx-select on the triggering element HxReselect = "HX-Reselect" // allows you to trigger client-side events after the settle step HxTriggerAfterSettle = "HX-Trigger-After-Settle" // allows you to trigger client-side events after the swap step HxTriggerAfterSwap = "HX-Trigger-After-Swap" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HxUrlVal ¶
func (*HxUrlVal) HasPathPrefix ¶
type Hxw ¶
type Hxw struct {
http.ResponseWriter
}
func Response ¶
func Response(w http.ResponseWriter) *Hxw
func (*Hxw) HxLocation ¶
func (*Hxw) HxRedirect ¶
func (*Hxw) HxTriggerAfterSwap ¶
Click to show internal directories.
Click to hide internal directories.