Triptych Proposals

Three small proposals for putting "hyper" back in the hypertext.

Proposal Issue Tracker
Support PUT, PATCH, and DELETE in HTML Forms Issue #3577
Button HTTP Requests Pending
Partial Page Replacement Pending

Explanation

Triptych is three simple proposals that make HTML much more expressive in how it can make and handle network requests.

If you are a practical person, you could say it brings the best of htmx (and other attributed-based page replacement libraries, like turbo and unpoly) to HTML. For the more theoretically-inclined, it completes HTML's ability to do Representational State Transfer (REST) by making it a sufficient self-describing representation for a much wider variety of problem spaces.

Basically, it should be easy to use HTML to declare page behavior that makes HTTP requests, and then tell the browser to either do a full-page navigation or replace part of the page with the response. Triptych enables this by bringing all the HTTP methods to HTML, giving buttons to ability to make requests without the help of a form, and making it possible to target a DOM subtree for replacement with the response.

I first outlined these proposals in The Life & Death of htmx at Big Sky Dev Con.

See also: the Triptych Polyfill (on GitHub).

Status

Working on an update to the fetch spec that's required to get CORS support in forms.

For a full history of changes to the Forms proposal, see the updates section.

Last Updated: Sept 22, 2024