Live data from Hacker News

React is holding me hostage

emnudge.dev

491–500 of 553 posts

Re: React is holding me hostage

#492
post #235

Earlier quoted context omitted.

I don't think you are living in the real world. Most React applications do not end up like that in the real world. They turn into poorly architected over complicated nightmares, particularly on sprawling apps which is the reality in the corporate space. Not everyone is building hyper-focused single function tools which can be crammed in an SPA type framework. And the users suffer for this. One of the finest turds I'v…

RE: Microsoft 1) MSFT has already used React for far longer than 2 years. 2) They have basically never used the technologies you mentioned (WPF, Silverlight, WinUI). They offer them as UI toolkits that run in their Windows environment and that’s it. Their failure to market and support these technologies is independent of what they do for their own development strategy. 3) They bought GitHub and effectively own electr…

> Many of their biggest apps are on electron (Teams, VS Code, Azure Data Studio).

Huh? Those are Microsoft's biggest apps? Not, MS Word, the NT Kernel or ... windows 11? The XBox operating system project? Outlook express? Visual Studio? ... Github?

I'll grant that Electron is used by a few teams at microsoft. But I'd be surprised if even 1% of microsoft's engineers worked on products built with electron.

Re: React is holding me hostage

#493
post #207

Earlier quoted context omitted.

Buy the average $400 windows laptop and $250 android phone and you'll see.

Would you? Most $400 laptops are on 10th gen Intel or such. Thats actually pretty good. A Pentium Gold is actually just on the edge of a modern i3 which in single core. Smokes most 8th gen chips. They are pretty good. $250 in an Android phone can get you a SD 695 5g these days. IT's not fast per say but it absolutely doesn't suck.

Yeah I agree with the GP. Most $400 laptops come pre-loaded with all sorts of janky crap that make that 10th gen intel CPU run like a wounded animal.

Most users have no idea how to remove any of it. Or, worse, they'll enable all of the preinstalled antivirus programs because they want their computer to be safe. And it gets worse. I visited my parents once and noticed something weird on my dad's macbook air. Turned out he'd gone out and bought Norton antivirus to install on it (!?). Norton installed a chrome extension which replaced the banner ads on every website he visited with their own ads. I manually deleted the extension from chrome, but norton put it right back again after chrome restarted.

If you don't believe me, use performance counters and measure it. Your website runs way slower on your users' computer than you think it does.

Re: React is holding me hostage

#494

``` The quickest obstacle you’ll run into as someone new to React will be something like this function MyComponent() { const [num, setNumber] = useState(42); // infinite loop setNumber(n => n + 1); return {num} } Trying to make state updates at the top level of a component will result in an infinite loop. ``` I've taught React to dozens of people without ever seeing someone try this. A render function is an idempoten…

Most people who use React don't understand idempotency, in my experience. Without understanding that fundamental concept, and that that React will blow away the tree and recreate it (albeit efficiently), one will not understand React.

Re: React is holding me hostage

#495

Earlier quoted context omitted.

I read this sentiment as basically saying the users experience of the app matters less than the experience of the dev who works on it.

I will take an app that's a bit slow but renders consistently over an app that works faster but sometimes forgets to update parts of UI, every time.

Why would performance and correctness be in opposition to each other? Is chrome more buggy because its fast?

Re: React is holding me hostage

#496
post #50

Not to start an unholy flame war, but if you were to start a new project and didn’t need to worry about the ecosystem or workforce, what framework would you choose? Vue? Svelte? Something else?

I'd still use React, purely to be able to use JSX without another templating language, and I think in its functional paradigm as well.

Re: React is holding me hostage

#497
post #2

"frontend engineers"

You've had this account for over a decade and this, a childish display of junior capability, is the pinnacle of your contributions.

That is honestly hilarious, I took a look at their other comment (singular), and this person waited literally over ten years just to post this comment. Wow.

Re: React is holding me hostage

#498

Earlier quoted context omitted.

If you need to fetch a piece of data when the component loads, how do you do it without useEffect?

You don't do that. Why would fetching data depend on whatever is being rendered? You know what data you need or not need before rendering anything, or you will be in a world of pain.

I am not sure I am following. Say your homepage has a link to a page that shows the top scorers in a league. Where/when does the fetching of the top scorers happen ?

Re: React is holding me hostage

#499

Earlier quoted context omitted.

React just went for JS naming of the attributes instead of html naming of the attributes. Reasonable, if annoying, choice.

False, for a lot of attributes you have to use the HTML naming of the attributes, so is not consistent, for example to use aria-label you have to write it exactly like that (not ariaLabel as when using JS)

aria-* and data-* apparently are the exception

More on that: https://stackoverflow.com/questions/52398380/why-react-wai-a...

Re: React is holding me hostage

#500

I'm still a React guy. I've also worked with Angular and Vue and toyed with Svelte. People tend to compare these frameworks on things that don't matter - often it's performance. We used to compare React performance to AngularJs performance too, which was meaningless. VDom is nice. Reactivity in signals is nice. Limiting rerenders is nice. But I choose frameworks because of developer ergonomics. The killer feature for…

How is performance not important in this context? React is very sluggish when updating many elements at once, for not very large values of "many". With some regularity, I've debugged React+MobX jank issues where a bigger update, such as switching from one panel to another, takes upwards of 200ms on a mid- or low-range machine. None of this is perceptible on our beefy dev boxes, which is why I think people disregard i…

No amount of speed will save you from a bad design.
Post reply on HN