Live data from Hacker News

React is winning by default and slowing innovation

lorenstew.art

151–160 of 866 posts

Re: React is winning by default and slowing innovation

#151
post #102

React is winning because its really good. Even if the cost is an extra few milliseconds of render time and few extra hours of dev time figuring out things like hook dependencies. If React starts taking a backseat, it'll be because its no longer really good. And, to be fair: I've started to see this happen. Next & Vercel have totally taken over the React world, and they've proven to make quite poor architectural decis…

Maybe us backenders help. If I need to do front end I learn as little as possible. React does the job. It could have been Angular that ended up being in the boring throne, and I would have said just use Angular. Just use what the world uses!

Angular is so much nicer and more batteries-included than React. React somehow manages to be massively yet incomplete: add a router, add state management, add react-hook-form...

Re: React is winning by default and slowing innovation

#152
post #112

Earlier quoted context omitted.

+1 React DX is really great. It started really great and it got weird and bloated but it's still really great relative to the JS landscape hell. But, also yes, it's a pain in the ass and a frustrating kind of necessary evil. So there is room for improvements. Nextjs is a living hell. The ironic thing is AI makes it dramatically more tolerable to the point it's actually pretty good. But that can't be a good thing in t…

Honestly I think React DX kinda sucks, at least in some areas. Performance is one of the worst (`useMemo` and `componentShouldUpdate` are way to easy to ignore, constant re-renders are the norm and writing performant React code requires conscious effort to avoid footguns) but it's also just less self-explanatory than the alternatives I've tried. I started doing web dev before reactivity frameworks were a thing, and I…

I think you've nailed it. It does come down to user preference.

React _is_ a whole new way of thinking. Back in the days of jQuery it was very painful to stitch together web experience across HTML+CSS+JS. jquery provided much needed DX around utilities to navigate across these pieces. But it was still way too easy to treat HTML like your database and model user-state across a Frankenstein of server, json, html, and javascript.

React was a paradigm shift. "Screw it, everything is javascript." The web depends on js runtime, we know we're going to need it. It starts to makes the best future-forward sense to use the only full programming runtime available. From DX pov this was spectacular to speed up prototyping. And you can finally truly model state purely from data.

What followed was a huge a mess (redux), but I always say, what do we expect? The web is a mess, and it's great because it's useful. Humans are a mess!

--- VUE: similar to angular I just don't align with "super-powered html attributes". It just doesn't make sense as a mental model. Because it's _not_ HTML spec and HTML is not a programming language. The more powerful the framework gets the more we reinvent a pseudo-programming language _through_ HTML. Angular was full-stop a no-go when I first saw it's for-loops in HTML.

Re: React is winning by default and slowing innovation

#153
"Choose boring technologies"

For many software projects, you don't want to take technical risk on something like a UI framework. React is now boring.

Personally, I want a browser UI framework that's more like desktop/mobile UI programming. Working with the DOM directly kinda-sorta tries to do this, but it's so fundamentally "weird" compared to just getting a pointer / reference to an item onscreen, that it's clear why the React way is much more popular.

Re: React is winning by default and slowing innovation

#154
post #120
post #37

Earlier quoted context omitted.

Yes, this is probably the wrongest statement. When React was launched, it was one in a pool of thousands of web frameworks. For any axis you want to claim that React won by "default", there was another framework that dominated React in that axis and lost anyways. Some frameworks had more resources and lost (Angular), some of which were more popular and lost (jQuery, Backbone), and some of which were even more hyped t…

It won by marketing and the angularjs to Angular breaking change. If they kept going with angularjs or had an upgrade path react wouldn't be default in the enterprise stack. That's all on Google. Meteor was node framework. jQuery is probably still more popular but it is only a lib. Vue had a Chinese language problem. React won because a framework by Facebook felt safe.

If every other framework failed because of , that does indeed sound like React won due to its own merits.

Re: React is winning by default and slowing innovation

#155
The reality is that for most situations choosing a technology you know well, is mature, and is proven, will almost always be the better choice. There's always going to be some small issue with a framework, and then suddenly you're pulling your hair out at 2am trying to hack together a solution to make it fit your specific needs. Web devs aren't complete idiots, most will be able to pick up a framework in a couple hours. They won't be able to pick up all the edge cases and foot guns for months or years. Better the devil you know.

Re: React is winning by default and slowing innovation

#156

I feel this with every fiber of my being. I used to do a TON of front-end work, some of it quite cutting edge, delivering highly performant user experiences in the browser that had previously been only thought possible in a native app. Back in like 2009-2015. I was deeply connected with the web standards fundamentals and how to leverage them mostly directly. I detoured into heavier focus on backend work for quite a w…

> It just basically does everything React does but better SolidJS still has some major pain points; the one I found was not knowing whether a prop was a signal or needed to become one. The type system doesn't help much. In React, you know for sure that if your reference changes, the component reading that reference as a prop will re-render. In Solid, it's less clear whether the update will be observed.

[deleted]

Re: React is winning by default and slowing innovation

#157
Web components are the way out of this trap. Every single framework that isn't React should be wholeheartedly supporting web components to make sure that they have access to a viable ecosystem of components and utilities without having to bootstrap an entire competitor to React and it's ecosystem.

While a lot of people view web components as competitors to frameworks, they don't really have to be. The just define an interface between component implementations and browsers so enable interop and reliable composition.

On top of the low-level APIs frameworks have a lot of room to innovate and customize:

- There is a huge range of possibilities an opinions on how to author components. Buildless, JSX, template literals, custom syntaxes and compilers, class-based, functional, etc.

- There is a lot room for gluing components together in different ways: custom component loaders, context protocols, SSR, suspense-like utilities, styling and theming frameworks, etc.

- State management cuts across the UI independently from components and has a lot of room for innovation.

Being able to say "Use our new Flugle framework, it works great with all the other frameworks and adds awesome scaffolding" should be a nice selling point and buffer against React monoculture, as opposed to building a different and much smaller silo.

Re: React is winning by default and slowing innovation

#158
post #6

> React didn’t win purely on technical merit A sentence written by someone who clearly hasn't worked on a large Angular 1.x project.

I always thought Angular 1.x was _fine_, so long as you had incredible discipline in your team and stuck to predefined patterns. React’s main benefit wasn’t technical, it was organisational. It’s so opinionated that it’s difficult for an incompetent developer to introduce very low quality code into the project. Meanwhile in AngularJS, a developer with a clever implementation idea was a terrifying prospect for future…

React's benefit was absolutely technical. Its component model and one-way data binding was so much simpler to reason about and elegant than Angular. So much so that they ended up copying it in Aungular 1.6 and Angular 2.x.

One of the biggest criticisms at the time (And perhaps still now) was that it wasn't opinionated at all. It didn't make assumptions as to how to do routing, or to fetch data, or to handle state. The community eventually converged towards a handful of solutions, like redux, but it was easy for each project to have its own combination of flavours and patterns.

Angular was an all-batteries-included MVC framework, with DI, testing framework, and one true way to do things. The reason why it's harder to introduce very low quality code in React is because React is just functions, returning JSX, executing when the function parameters change.

On the other hand, angular had comically large footguns due to its very high complexity. Have a look at the legacy documentation, the page about "scopes" by itself is longer and introduces more concepts than the entire "Thinking in react" page.

Re: React is winning by default and slowing innovation

#159
I use html and server side rendering. The whole react thing has passed me by. If I need to use a js framework to add interactivity it’s Alpine. But then I just ask myself the question? Is this bad design? And if the answer is yes, I look for a vanilla html approach. Bye the way... the answer is always yes.

Re: React is winning by default and slowing innovation

#160
Over 10 years writting front ends. I hate react, but this article is junk, it advocates for new "reacts". This exact mentality is what got us the bad parts of React, and it's going to give us the bad parts of whatever next library.

All the problems that react faces had already been solved by another framework, YEARS in advance. That framework is ember.js. And you know why? Because react started out as an view layer library, it was not meant to be a full blown front end framework from the beginning and it paid the price. But hipsters kept looking at how fast it rendered 10 million rows instead of focusing on what actually matters FOR EVERY TOOL YOU USE:

SCALABILITY!!!

Does your tool scale? ALL freaking frameworks feel great while writting Todo MVC. But how does feel writting a huge app? That's where decisions matter. And ember.js got these decisions right, everyone is reinventing those decisions (in worse ways) and calling it innovation. You're not innovating, you are reinventing a wheel, having not even learned your lesson from previous experience.

Having done that rant, and having said i hate react, react has become mature enough (with a big ecosystem) to let you do your job decently enough. Give me a freaking break. Let me use a tool for 3 years without having to re-learn a new API.

Post reply on HN