News for hackers. Stuff that matters.
Re:The future of web software is HTML over WebSockets by bitsen on Thursday February 25, 2021 @05:43PM (#26269271)
I bet your ass that at least half of the developers reading HN don’t have caching of JS fully figured out such that when the JS changes server-side and immediately needs reloading on the client side that it does then and there instead of on the next request, the next page refresh, or never because they’ve f’d it up.

With server-fed, event-driven pages, you could potentially force refresh.

Re:The future of web software is HTML over WebSockets by galaxyLogic on Friday February 26, 2021 @02:01AM (#26272051)
I leave the browser waiting for a fetch-response from the server. The server responds only later when the page that is open in the browser was updated on server. Seems to work much of the time, but sometimes it seems Chrome closes the connection after a timeout and shows a network error in the dev-tools. FireFox not.

I assume web-sockets could make it work more robustly.

Re:The future of web software is HTML over WebSockets by lootsauce on Thursday February 25, 2021 @10:45PM (#26271167)
my solution to version changes in a rest api is to sent a version header with every response, the app checks it and if it does not match reloads the page, thus loading the new js.
Re:The future of web software is HTML over WebSockets by mikeryan on Thursday February 25, 2021 @11:17PM (#26271317)
I would not accept your wager. That being said if this was a “really big problem” I’d bet you that most developers on HN would have an idea how to address it.