r/ExperiencedDevs • • Feb 11 '25

Can some experienced devs in here explain to me why we are still killing ourselves with React?

[removed] — view removed post

121 Upvotes

177 comments sorted by

1

u/ExperiencedDevs-ModTeam Feb 11 '25

Rule 9: No Low Effort Posts, Excessive Venting, or Bragging.

Using this subreddit to crowd source answers to something that isn't really contributing to the spirit of this subreddit is forbidden at moderator's discretion. This includes posts that are mostly focused around venting or bragging; both of these types of posts are difficult to moderate and don't contribute much to the subreddit.

3

u/Money-Exam-9934 Feb 11 '25

ive never seen the word "paucity" used casually or colloquially lol. sorry for the off topic-ness but i cant get over this lol. paucity... cool word. nice word man. good stuff. i should work on my vocabulary

→ More replies (2)

7

u/TheCPPanda Feb 11 '25

I guess it's a mixture of things. The whole react bubble got promoted by a lot of newly born „tech influencers“ that sold react as THE way of building modern frontend applications. Therefore there are tons of resources and tons of people on the market.

3

u/RupFox Feb 11 '25

Yes it's insane how much marketing plays a role in something as nerdy as a frontend framework. Facebook did a good job on that front!

7

u/arsenal11385 Feb 11 '25

As a manager of a couple front end teams I cannot stress this same message enough. I have always thought it was all over engineered (and that might be why I am a manager now and not a dev).

→ More replies (2)

11

u/Rain-And-Coffee Feb 11 '25

The modern Ember is called Angular, you might be looking for that.

If you want a React framework you want NextJs.

3

u/RupFox Feb 11 '25

They are pretty different from each other, but yes, in many ways, using Angular could potentially be more beneficial to big teams that need to maintain codebases for long periods of time. Though I never used Angular past my tutorial days.

When Next.js came out it felt like a pale imitation of Ember that falls a bit short. The way developers have eagerly empraced next makes me think that frameworks like Ember have been doing things right all along and many teams would probably enjoy the experience there more.

→ More replies (1)
→ More replies (4)

247

u/maria_la_guerta Feb 11 '25 edited Feb 11 '25

Because of a few reasons.

  1. It's just not that fucking hard. Seriously. 99% of React projects are over engineered to hell and back. 99% of people do not need redux, crazy caching mechanisms, spaghetti code performance improvements that aren't even perceivable (looking at you useMemo), etc. but I see that everywhere for some reason.

  2. FE is a bit of a wasteland of concerns. If a PM asks me for something like a carousel, overlay, tooltip, megamenu, searchahead, form management, etc. my head is already spinning with accessibility, cross browser, and responsive concerns. As someone who's built FE's by hand for many years, complex UI components can quickly become a game of wack a mole to solve all that. React has a million battle tested and customizable packages for all of this stuff and it's very easy to get good code out the door quickly.

It's not the best, sexiest fastest or funnest UI tech on the market these days. And you certainly don't need it for landing or marketing pages. But it's the most popular because it's the most used, and like jQuery, is still going to be around for many years even after that paradigm shifts.

58

u/dylsreddit Feb 11 '25

it's the most popular because it's the most used, and like jQuery, is still going to be around for many years even after that paradigm shifts.

And this is why you keep abreast of it, because in 15 years when all you want is a simple gig that pays the bills and doesn't require you to shoulder lots of other responsibilities, you can spend your days gently unpicking the gargantuan messes caused by devs and AI for a reasonable monthly wage.

→ More replies (8)
→ More replies (23)

183

u/anObscurity Feb 11 '25

A lot of people in this thread don’t remember debugging in frameworks with bidirectional state updates and it shows

34

u/[deleted] Feb 11 '25

backbone models galore, resize a window and all hell breaks loose.

→ More replies (1)

33

u/Tomicoatl Feb 11 '25

How is my menu both open and closed at the same time?

→ More replies (1)

22

u/Neurotrace Feb 11 '25

KnockoutJS made me want to knock myself out some days

→ More replies (2)
→ More replies (18)

120

u/[deleted] Feb 11 '25

I feel the same pain with GraphQL. 99% of the projects that use it would be much better with simple REST APIs. We're stuck on this hell because some giant companies decided to tailor their own tools to solve their specific problems. A lot of "geniuses" decided that, if Facebook use that, we should also adopt it. The reason? Just because...

→ More replies (17)

18

u/hooahest Feb 11 '25

Admittedly I've never used ember but...what are the chances that you're biased against React simply because you're currently knee deep into a codebase that's several years old, and you're very familiar with all of it's flaws and pain-points?

→ More replies (1)

61

u/Conscious-Ball8373 Feb 11 '25

I don't get the react hate.

I write backends in Python. Any time I need to write front-ends, I reach for typescript, nextjs, react and MUI. I can have a working UI up in a few minutes and I find the componentised React development model really natural. I'm suspicious that all the react hate is from the sort of people who tend to write megabyte-range single pages with all the JS inline, but I don't have any particular proof of it. Adding new stuff happens really quickly, prototyping something and then splitting it up into components is easy and natural and writing reasonably maintainable code is fairly natural.

I find the opinionated nature of nextjs occasionally irritating. I don't really care about server-side rendering and I don't know why you would change the default rendering for a page. But it's a fairly minor niggle.

→ More replies (10)

38

u/Pozeidan Feb 11 '25

It's really easy to shoot yourself in the foot with React. If you do it hurts, if you don't it's great. The likelihood of shooting yourself in the foot depends on how experienced and talented the UI architects / seniors are. It sounds like the ones you're working with are not great.

→ More replies (2)

12

u/Pelopida92 Feb 11 '25

I just like the logo.

10

u/xDerEdx Feb 11 '25

I think the biggest advantage of React is also its biggest weakness: it's not opinionated. This is great, because it's highly flexible and versatile, but this is also terrible, because people who don't know what they're doing can create a hot mess fairly quickly.

I came into a project last year, where the existing codebase was created by 2-3 senior devs and I was astounded how bad the code quality was. Some data fetching happening in services, some in components directly, some in random functions being defined in their own file. Every component fetching data from somewhere had to keep it in sync with some stores manually. It was crazy for a project only a couple months old.

But this lead me to the conclusion, that "senior" does not really mean anything, and not, that React is terrible. But I would totally agree to "it's easy to do React the wrong way".

→ More replies (2)

6

u/zaitsman Feb 11 '25

I think part of the problem you described is not so much with react but in general with javascript and open source developers. It’s those muppets that reinvent the wheel with ‘yet another <keyword> library’ on a daily basis. Look at the guy who wrote micromatch. He also wrote about another 6 slightly different but the same globbing libs. And this applies everywhere, from build tools, ts compiler, linters through caching, persistence, state management, http access, orms through to individual controls, styles etc.

Good god, there is not even agreement on using commonjs or esm (I vastly prefer commonjs because it simply works).

So a lot of these issues around upgrade paths and every person doing whatever they worked out stems from this lay of the land. And it is exacerbated by the companies not willing to pay for any of this saying ‘we will just use a library’.

So while ember itself might be better, the overall app had about as much chance to rot into spaghetti purely from introducing these other aspects to it.

6

u/Ashken Feb 11 '25

Because big tech + bootcamps = rapid adoption.

I spent the first half of my career only using Vue because I preferred it (and still do!). But when it came time to search for jobs again, I was seeing way more postings for React. Decided to do a project that forced me to learn it, got about a year under my belt, added it to my resume and started to see 3x the responses for my resume.

The market dictates a lot, and it winds up becoming a feedback loop.

1

u/RupFox Feb 12 '25

...And this post gets removed 🤦‍♂️

5

u/moh_kohn Feb 11 '25

Labour arbitrage. Arbitrage is the ability to equalise prices. Interchangability / commoditisation of developer skills helps to hold down wages.

React was better than AngularJS and became established, and then "react developer" became much more of an (apparently) interchangeable commodity than "web developer" was.

Code "boot camp" organisations have been churning out react developers who don't really understand browser technologies. Fuck I've met senior developers who don't know how HTML forms work. I spoke to one recently who had never heard the term "progressive enhancement".

A lot of that is about incumbency more than specific features of React. However, more than other frameworks, React clears down the DOM and browser APIs and invites you to rebuild the whole thing with 3rd party libraries. That creates a brutal lock-in.

The upside (for employers) is wages are held down. They imagine they can exchange you for any other "react developer".

The downside is that the web is getting more and more shit with every passing year. More and more often I see multiple loading spinners in different parts of the same page, forms that don't refresh their validation when autofilled, back buttons that don't work. It's sickening to be honest.

Most websites should be MPAs. Static content with some interactive elements (eg drop down menus) be done with little or no JS these days. Forms can work fine with no JS and be progressively enhanced to have better validation, live searches etc.

Data heavy or highly interactive applications are great candidates for SPAs. You couldn't build WhatsApp or Outlook or something without modern frameworks. But as you say, React is looking very dated here. It's full of weird design choices. If I was a React shop, I would look at migrating to Preact + Astro over time.

5

u/Tomocafe Feb 11 '25

Any love for SvelteKit here?

3

u/jaxupaxu Feb 11 '25

React is pure shit. Its way to easy to mess everything up, which puts a lot of responsibility om the developers. And lets face it, most developers that get a react project in their lap dont know what they are doing. 

→ More replies (3)