←back to thread

306 points carlos-menezes | 2 comments | | HN request time: 0s | source
Show context
tjoff ◴[] No.41893322[source]
Industry will do absolutely anything, except making lightweight sites.

We had instant internet in the late 90s, if you were lucky enough to have a fast connection. The pages were small and there were barely any javascript. You can still find such fast loading lightweight pages today and the experience is almost surreal.

It feels like the page has completely loaded before you even released the mousebutton.

If only the user experience were better it might have been tolerable but we didn't get that either.

replies(6): >>41893360 #>>41893625 #>>41893919 #>>41894650 #>>41895649 #>>41896257 #
OtomotO ◴[] No.41893360[source]
I am currently de-javascripting a React app of some project I am working on.

It's a blast. It's faster and way more resilient. No more state desync between frontend and backend.

I admit there is a minimum of javascript (currently a few hundred lines) for convenience.

I'll add a bit more to add the illusion this is still a SPA.

I'll kill about 40k lines of React that way and about 20k lines of Kotlin.

I'll have to rewrite about 30k lines of backend code though.

Still, I love it.

replies(3): >>41893417 #>>41893847 #>>41904214 #
pushupentry1219 ◴[] No.41893847[source]
Honestly I used to be on the strict noscript JavaScript hate train.

But if your site works fast. Loads fast. With _a little_ JS that actually improves the functionality+usability in? I think that's completely fine. Minimal JS for the win.

replies(3): >>41893980 #>>41894499 #>>41894626 #
starspangled ◴[] No.41894499[source]
What do you use that good javascipt for? And what is the excessive stuff that causes slowness and bloat? I'm not a web programmer, just curious.
replies(2): >>41895569 #>>41895617 #
graemep ◴[] No.41895569{3}[source]
Two examples that come up a lot for me:

1. filtering a drop down list by typing rather than scrolling through lots of options to pick one 2. Rearranging items with drag and drop

The excessive stuff is requiring a whole lot of scripts and resources to load before you display a simple page of information.

replies(1): >>41897193 #
1. LtWorf ◴[] No.41897193{4}[source]
Doesn't the combo box input field already do this?
replies(1): >>41902809 #
2. graemep ◴[] No.41902809[source]
You are right, it does.

A better example would be dynamically loading the list of options where it is very long and loading the entire list would make the page size much larger.