You know what made javascript so common, accessible, and thus later universal?
Putting things on a screen was (is) stupidly simple.
That's the whole thing. It's not the types or npm or whatever. It's that you could start with C/Python/Java and spend your first 6 months as a coder printing and asking values on a dark terminal (which is something a newbie might not even have interacted with before) or you could go the html/css/javascript route and have animations moving in your screen you can show to your friends on day one.
Everything flows from that human experience. UIs are Electron because creating UIs for a browser is an extremely more universal, easy and creative-friendly experience than creating UIs for native apps, particuarly if JS is your native language for the previously stated reason.
The industry failed to adapt to the fact that the terminal wasn't any longer the reality of computer users, and the web kinda filled that niche by default.
Also, React was an answer to the advent of mobile phones, tablets, smart tvs, and basically all the explosion of not-a-desktop computer form factors. You could no longer assume your html was a proper format for everything. So you need an common API to be consumed by a mobile app, a tv app, a tablet app... react was the way to make the web another of the N apps that use the api, and not get special treatment. The idea made sense in context, back then.
> Putting things on a screen was (is) stupidly simple.
This is why HTML is still a great language for building UIs and that's why Visual Basic had a huge success in the early 90s: drag UI components on a panel, write the callbacks for clicks, save and distribute the exe. Almost anybody could do it.
React and its siblings are much more complicated than that.
> The industry failed to adapt to the fact that the terminal wasn't any longer the reality of computer users
I'm still waiting for some GUI-based terminal to appear
I want to call git in Scratch!
It’s so very ironic that your comment appears on this particular post. We had a much better version of this with interface builder on NeXT in the late 1980s (and later Mac OS X). Similar tooling existed for DOS and Windows.
You literally laid out your UI in a WYSIWYG, drag and dropped connections to your code, and had something working on day one.
It was even easier than the web, because what you were laying out were full components with code and UI and behavior. The web still hasn’t caught up with that fully.
When I see comments like these, I better understand why old timers shake their fist at the youngsters reinventing the wheel badly because they don’t understand what came before.
BASIC made it even easier to put things on a screen. We had commands like this:
In Apple BASIC:
- HPLOT x, y
- HPLOT x1, y1 TO x2, y2
In QuickBASIC on MS-DOS:
- PSET (x, y), color
In contrast I don't find HTML to be "stupidly simple" at all.