htmx-0.1.0.1: Use htmx with various haskell libraries
Safe HaskellSafe-Inferred
LanguageHaskell2010

Htmx.Extension

Description

This module defines a sum type that represents the "included" HTMX extensions https://htmx.org/extensions/#included

Synopsis

Documentation

data HtmxExtension Source #

https://htmx.org/extensions/

htmx includes a set of extensions out of the box that address common developer needs. These extensions are tested against htmx in each distribution.

You can find the source for the bundled extensions at https://unpkg.com/ browsehtmx.org@1.9.12distext. You will need to include the javascript file for the extension and then install it using the hx-ext attributes. See the individual extension documentation for more details.

Constructors

AjaxHeader

https://htmx.org/extensions/ajax-header/ includes the commonly-used X-Requested-With header that identifies ajax requests in many backend frameworks

AlpineMorph

https://htmx.org/extensions/alpine-morph/ an extension for using the Alpine.js morph plugin as the swapping mechanism in htmx.

ClassTools

https://htmx.org/extensions/class-tools/ an extension for manipulating timed addition and removal of classes on HTML elements

ClientSideTemplates

https://htmx.org/extensions/client-side-templates/ support for client side template processing of JSON/XML responses

Debug

https://htmx.org/extensions/debug/ an extension for debugging of a particular element using htmx

EventHeader

https://htmx.org/extensions/event-header/ includes a JSON serialized version of the triggering event, if any

HeadSupport

https://htmx.org/extensions/head-support/ support for merging the head tag from responses into the existing documents head

IncludeVals

https://htmx.org/extensions/include-vals/ allows you to include additional values in a request

JsonEnc

https://htmx.org/extensions/json-enc/ use JSON encoding in the body of requests, rather than the default x-www-form-urlencoded

Idiomorph

https://htmx.org/extensions/idiomorph/ an extension for using the idiomorph morphing algorithm as a swapping mechanism

LoadingStates

https://htmx.org/extensions/loding-states/ allows you to disable inputs, add and remove CSS classes to any element while a request is in-flight.

MethodOverride

https://htmx.org/extensions/method-override/ use the X-HTTP-Method-Override header for non-GET and POST requests

MorphdomSwap

https://htmx.org/extensions/morphdom-swap/ an extension for using the morphdom library as the swapping mechanism in htmx.

MultiSwap

https://htmx.org/extensions/multi-swap/ allows to swap multiple elements with different swap methods

PathDeps

https://htmx.org/extensions/path-deps/ an extension for expressing path-based dependencies similar to intercoolerjs

Preload

https://htmx.org/extensions/preload/ preloads selected href and hx-get targets based on rules you control.

RemoveMe

https://htmx.org/extensions/remove-me/ allows you to remove an element after a given amount of time

ResponseTargets

https://htmx.org/extensions/response-targets/ allows to specify different target elements to be swapped when different HTTP response codes are received

Restored

https://htmx.org/extensions/restored/ allows you to trigger events when the back button has been pressed

ServerSentEvents

https://htmx.org/extensions/server-sent-events/ uni-directional server push messaging via EventSource

WebSockets

https://htmx.org/extensions/web-sockets/ bi-directional connection to WebSocket servers

PathParams

https://htmx.org/extensions/path-params/ allows to use parameters for path variables instead of sending them in query or body