Fyzbo

joined 1 year ago
 

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.

[–] Fyzbo@programming.dev 1 points 7 months ago (1 children)

App router, where the directory structure controls the url.

 

Hi! I'm hoping someone can point me to best practices in regards to API cookies, NextJS, and SSR.

What I'm encountering is that I'm calling an external API that is trying to set some cookies on the browser. This works when the call is made directly from the browser to the API. However, if the API call is made from the SSR function, then the cookie data never makes it to the browser.

In this way the cookie is thrown away and never sent for follow-up requests.

What is the best way to handle these API cookies when using SSR? Is there a way to have NextJS pass them back to the browser or remember them for subsequent calls. Any advice, links, or videos would be very helpful.

[–] Fyzbo@programming.dev 1 points 11 months ago

It was tagged such that it shows up on Wikipedia as the JavaScript Mascot - https://en.wikipedia.org/wiki/File:JavaScript_mascot.svg

The user has also been actively deleting any other designs submitted to wikimedia.

[–] Fyzbo@programming.dev 1 points 11 months ago (1 children)

Does anyone know how to delete content from Wikimedia content?