Hacker News new | ask | show | jobs
by mickeyp 1290 days ago
That ecosystem moves very fast and... reinvents itself all the time.

Here's another way of looking at that problem:

How many of those tools and technologies existed 1, 3, 5, 10 years ago?

Would you trust a six month-old tool on github to form the nucleus of your -- probably mundane, in the good way! -- project? Would you risk it all for the chance to have a slightly different way of rendering CSS or generating HTML?

... I didn't think so. React's been around for a long time now and it's got a lot of momentum and people who know it. So that's a pretty safe bet. Rinse and repeat.

Not all tools are critical and you do have some leeway. But when in doubt, pick something you can easily hire people to help you accomplish; that has been around a while; and that feels established.

1 comments

> React's been around for a long time now and it's got a lot of momentum and people who know it.

That was true for jQuery as well; and yet, it is clearly no longer the right thing (tm) to choose for a project. Not because it's no longer cool; but because the underlying technology — the web browser — has gotten so much better it is no longer relevant.

Same fate may await React. At least, with jQuery it's pretty straightforward to gradually wean oneself off of it. I don't know how firmly we are going to be stuck with React when its time comes.

It wasn’t a change in web browser tech

It was that someone put in the time to write a JS preprocessor that went along with their framework. That was React’s novel addition

Without a preprocessor, users of your framework either use plain JS to generate HTML (i.e. jQuery) or you use templates.

Both of them always looked really ugly on frontend

With React’s JSX preprocessor, you can write HTML by… writing HTML. And you can mix custom components without doing some weird and ugly syntax

Does React use a shadow DOM? Yes, but so could have jQuery or Handlebars.js too, and it wouldn’t have mattered. People don’t care how it works as long as it works. As far as libraries go, what gets adopted is what looks and feels the nicest — as it should be

> Does React use a shadow DOM? Yes

No. You must be confusing it with virtual DOM.

As for React, what we are currently observing is that 1) it's a fairly large library in itself (~50kB of minified gzipped javascript); 2) it has a relatively slow DOM update mechanism; 3) it rerenders too eagerly, making it too easy to further degrade performance; 4) it's a lock-in into a non-standard jsx syntax, forever tying you to preprocessors.

What conclusions an architect would make looking at all this, I do not know.

Jquery got squashed from two directions. One being react and other data binding frameworks, the other side being browser tech modernizing and aligning, such that bare js could be used, without a thick compatibility layer in between.
jQuery has existed for a long time, still gets updates, is still used in greenfield projects, and has a large body of expertise around it.

The concern is abandoned projects that no one knows how to use, not that something is a bit old. React is beyond that point. It's not just the tech junkies hopping from the latest fad using it. There's been enough widespread adoption that there will still be React projects in 20 years.

Nevertheless the point is the same. Some technologies are more stable and broadly adopted than others. A slice of the total risk management pie entails selecting a tech stack that is less likely to die soon than its competitors.