this post was submitted on 08 Jul 2024
17 points (100.0% liked)

JavaScript

1989 readers
1 users here now

founded 1 year ago
MODERATORS
 

I was watching a youtube video explaining HTMX targets and using it to pull HTML from a URL and push the HTML into a div element.

https://htmx.org/docs/#targets

This immediately reminded me of JQuery's .load() which can pull a URL and up the HTML in an element.

$( "#result" ).load( "ajax/test.html" ); https://api.jquery.com/load/

What caught me off guard is how the speaker talked about this being an entirely new technique, pulling HTML instead of JSON from an API.

It made me realize that new developers who started after the creation of ReactJS, SPA/PWA have no concept of AJAX and the interesting ways developers used to merge the client and server.

I have no interest in going back to a JQuery dominated world... or the chaos of JS development before JQuery, but it's interesting to see that what is old is new again.

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 1 points 4 months ago

There's also Rails and Hotwire, which works like this.