Live data from Hacker News

Does anybody like React?

jsx.lol

311–320 of 353 posts

Re: Does anybody like React?

#311
post #205

Earlier quoted context omitted.

> A bit out of date > article just about to turn three years old JavaScript community never beating the allegations lol

I skimmed through it, and I think the only thing that is out of date is the section on `zone` in Angular. In october 2025, they changed to `zoneless` by default, which uses signals just like Vue. This was a long time coming imo, as the major criticism of Angular was how poorly update management was handled. Also Svelte runes aren't mentioned, as that came out three months after this post. Runes are essentially also s…

The other thing out of date is Svelte using compile-time tracking — Svelte now also uses runtime tracking, i.e. signals.

At this point, I think React and Lit are the only major frameworks not using signals. And I'm not 100% sure about Lit.

Re: Does anybody like React?

#312
post #9

I read one post before that really resonates with me, couldn't recall from where though: You love JSX, you don't love React Many of the jobs in my location requires React though, so I have to tolerate it somehow.

There's several frameworks that use JSX but don't act like React. I definitely have found myself in the "I love JSX but don't always love React" camp. I used Cycle.JS for a while, but came back to React for the ecosystem.

For what it is worth, I'm rather proud of my smaller reactive (RxJS-based) JSX alternative (Butterfloat), which is not a Virtual DOM like React or Cycle.JS (it is more "What if Knockout but TSX?"), and I am working on its second version now (among other things expanding its SSR/SSG powers, which already have a very different, I'd argue simpler, take on SSR/SSG than the Next.js/Nuxt.js/React Server Components world).

Re: Does anybody like React?

#313

As someone who lived through all major waves of JS for the last ~16 years, I do love react, in a sense: React is the worst JS framework except for all the others we've tried. I'd take React over the Angular 1 days any time. I'd take Angular 1's full-bodied MVC over the "build it yourself from scratch every time" approach of Backbone. I'd take Backbone's minimal MVC structure over the classic JQuery Soup architecture.…

Curious to see where you'd place Knockout (still my favorite framework to date)

Re: Does anybody like React?

#314
1. use web-components

2. if one is too much then use Svelte to make 1. Svelte works perfectly okay with other JS libraries without needing wrappers.

3. use Vue if things get political(i.e we need devs) if you need to play around but u can also use Vue to make 1.

1000xxx. if you tokens to burn & VC money to burn the use React - since your decisions are influenced by politics of the day and not pleasing your users.

Re: Does anybody like React?

#315
post #84

What if: 1. JS supports JSX literals so let elDef = Text ; will be compiled into let elDef = ["div", {id:"some"}, ["Text"]]; 2. We extend DOM API to accept such constructs: element.append(elDef); // same thing as element.append(" Text "); element.prepend(elDef); // ditto element.patch(elDef); // patch element's DOM by elDef 3. Add appropriate events: componentDidMount, componentWillUnmount, etc. for cases when tag in…

If you are making it native to the browser, why have a "virtual DOM" "definition language" middleman and not just jump straight to real DOM, the browser's existing bread and butter?

  let ele = Text // ele is now HTMLDivElement
Doing that `element.append(ele)` just works with existing DOM APIs.

Instead of supporting classes and functions in browser-supported JSX with their own life cycle model, you can just require registered Web Components and reuse existing Web Component life cycles.

I think if Browser-native JSX support were to happen it should probably either be real DOM or remain a function tree so that at least some tree operations can be amortized by the function compiler.

Which is that most JSX is actually compiled to nested calls like:

    let elDef = jsx("div", {id:"some"}, "Text", jsx("div", {id: "inner"}, "Text2"), ...otherChildren)
The `jsx` function can potentially avoid some future tree walks/recursion by the nature of being unrolled by the compiler into nested calls instead. That's a useful property lost in trying to agree on a single virtual tree definition. It's also one maybe unnecessary if just relying on real DOM trees, because browsers have their own optimizations for DOM tree walking.

Re: Does anybody like React?

#316
post #313

As someone who lived through all major waves of JS for the last ~16 years, I do love react, in a sense: React is the worst JS framework except for all the others we've tried. I'd take React over the Angular 1 days any time. I'd take Angular 1's full-bodied MVC over the "build it yourself from scratch every time" approach of Backbone. I'd take Backbone's minimal MVC structure over the classic JQuery Soup architecture.…

Curious to see where you'd place Knockout (still my favorite framework to date)

We'll set aside performance because that could be fixed with a renderer rewrite.

The biggest issue when I worked with it was weaving a spiderweb of bindings that eventually trap you. At some point, you wind up spending most of your time fighting weird bugs that show up in places very far removed from the bindings that actually caused the bug.

Re: Does anybody like React?

#317
post #313

As someone who lived through all major waves of JS for the last ~16 years, I do love react, in a sense: React is the worst JS framework except for all the others we've tried. I'd take React over the Angular 1 days any time. I'd take Angular 1's full-bodied MVC over the "build it yourself from scratch every time" approach of Backbone. I'd take Backbone's minimal MVC structure over the classic JQuery Soup architecture.…

Curious to see where you'd place Knockout (still my favorite framework to date)

Unfortunately I never got around to trying it! I remember it being a contender around the time of Backbone, but then Ember and Angular were the main options thereafter.

Re: Does anybody like React?

#318

Earlier quoted context omitted.

Svelte is cool although I didn't have some big epiphany. I'm not going to use Svelte because "it compiles" and "is faster" when my existing React app performs very well. Plus there are some libraries for my specific use case that didn't exist in Svelte. I know people love things besides React, and I would be happy to see it unseated. Sure I'm part of the problem but it's been good to me and I have bigger fish to fry.

> Plus there are some libraries for my specific use case that didn't exist in Svelte. A lot of these libraries aren't needed in Svelte because 1) the functionality might already be built into Svelte, and 2) you can use any JavaScript library directly, unlike in React where you often need a React-specific wrapper. Not saying that applies to your specific use case, but I've seen this argument way too many times.

As someone who has written both React and Svelte for many years I must interject. React is itself just a library. No, you don’t need any specific “wrappers” for it. Let’s not mislead the readers here.

Re: Does anybody like React?

#319

I think so, because it's created in Meta, thus having a huge developer base already and spread its way out of there. If you earn your life writing it, because your employer forces you to do so and you never try other stuff that long, you end up liking it. I have never found the idea of having a Virtual DOM and diffing in runtime a good solution to the problem, maybe that's why I never liked React. I mean if you are w…

I remember when React's vdom renderer was faster than anyone and it wasn't even close. InfernoJS uses a vdom and is still one of the fastest JS frameworks out there, so I don't know that diffing is always inherently slower.

Re: Does anybody like React?

#320
post #212

More than React, I'm interested in the question of how to best write UI through code, in general. Even though I'm a fan of React, and use it for practically every web application I build, my biggest and most obvious issue has been that writing UIs through React doesn't feel as natural as, say, writing command line tools in Go, or live/realtime apps in Elixir. Some languages just feel incredibly natural and frictionle…

As an engineer, it's easy to look at every problem and think to yourself: "There is a perfect solution for this, we just haven't found it yet." Yet, as the years go by, I find myself accepting a less idealistic answer: Maybe there isn't. Maybe the problem space is just so complex that no one (humanly feasible) general solution exists for all forms of it. If there's one thing that this is true for, UI is probably it.

Years are a pretty short time frame as it relates to technology, though. Even for software.

The solution might be well out of grasp now, but think 10, 20, 100 years from now. Somebody smart with a new perspective will eventually come around and tear out the roots, and we'll all be better for it. Perhaps what's holding us back isn't the problem itself, but the way we approach it and the assumptions we bring.

Trying is at least worth the effort, especially since "better" is very achievable, rather than total perfection.

Post reply on HN