hx-pod cover image

hx-pod

Advanced htmx: Season 2 recap, grouping the 13 advanced attributes

Apr 12, 2024
20:04

Advanced htmx: Recap & grouping each of the 13 advanced attributes we went over this "season"

This means we have now gone through every attribute! (not counting extensions)

1. Browser & History

Hx-push-url - set your url

Hx-replace-url - replace your url, save no snapshot

Hx-history-elt - change snapshot from default to particular element

Hx-history - prevent something from being saved in the htmx snapshot

2. Customizing Requests

Hx-request - set no headers or timeout on request

Hx-headers - set custom headers, dynamic or static json

Hx-sync - allows you to set rules for multiple htmx requests at once

3. Submitting Data

Hx-validate - allows you to use validation rules outside of forms

Hx-disabled-elt - disables a button once you’ve clicked it

Hx-encoding - allows you to upload files via Ajax

4. Overriding Htmx

Hx-disable - allows you to disable htmx for user comments, posts, etc

Hx-disinherit - breaks inheritance chain for one or more attributes

5. Fun!

Hx-select-oob - lets you place element from your response wherever you want

Get the Snipd
podcast app

Unlock the knowledge in podcasts with the podcast player of the future.
App store bannerPlay store banner

AI-powered
podcast player

Listen to all your favourite podcasts with AI-powered features

Discover
highlights

Listen to the best highlights from the podcasts you love and dive into the full episode

Save any
moment

Hear something you like? Tap your headphones to save it with AI-generated key takeaways

Share
& Export

Send highlights to Twitter, WhatsApp or export them to Notion, Readwise & more

AI-powered
podcast player

Listen to all your favourite podcasts with AI-powered features

Discover
highlights

Listen to the best highlights from the podcasts you love and dive into the full episode