htmx icon indicating copy to clipboard operation
htmx copied to clipboard

Suggest: split ajax module as extension to isolate htmx core with ajax implementation

Open kitepad opened this issue 2 years ago • 0 comments

Currently, ajax module is part of htmx core, and implement by XMLHTTPRequest. But most core functions are about dom, and as we know, The Fetch API is a new and modern interface that allows you to make HTTP requests in the web browsers. So I suggest abstract an API layer in core, and api implementation layer as extension, default implementation is based on XMLHTTPRequest. Other implementations can be provided by extension contributor, such as Fetch API based implementation.

kitepad avatar Jun 30 '22 05:06 kitepad