Live data from Hacker News

React is holding me hostage

emnudge.dev

451–460 of 553 posts

Re: React is holding me hostage

#451
post #425

Earlier quoted context omitted.

> It's easy to hire people, onboard people Yes they'll know the React part. It's the Redux/Mobx/React Router/whatever snowflake libraries you chose part that will be more difficult. I really don't like incomplete solutions personally.

Its all about preferences, I tend to prefer seasoned devs who have had the chance to try different things and form their own opinions. Someone who has relied on framework magic they don't understand through their careers tend to be less resilient to change

Why do you assume they do not understand the single framework "magic" yet others do understand React's ecosystem?

Re: React is holding me hostage

#452

Earlier quoted context omitted.

Sorry. The biggest problem is that useEffect's mental model is based on data change and not on events. So instead of "do something when this action/event happens" we get "do something when this data changes". Which ends up being abused a lot, as developers who aren't familiar with this mental model (which is most of them), tend to lump up every action into a data change. So instead of something like (contrived exampl…

I think your example was good, but I disagree with your conclusion. In your example, the hooks version renders the UI based on data/state. In the non-hooks version, the state of the rendered UI depends on ephemeral events and the order they were dispatched. The hooks version is more easily tested and it's easier to reason about as a developer. It conforms to the mental model of a function (props, state) => UI. The no…

Also I’m pretty sure it don’t add data dependencies! Only the the dependencies that retrigger the effect

Re: React is holding me hostage

#453

Earlier quoted context omitted.

Sorry. The biggest problem is that useEffect's mental model is based on data change and not on events. So instead of "do something when this action/event happens" we get "do something when this data changes". Which ends up being abused a lot, as developers who aren't familiar with this mental model (which is most of them), tend to lump up every action into a data change. So instead of something like (contrived exampl…

I think your example was good, but I disagree with your conclusion. In your example, the hooks version renders the UI based on data/state. In the non-hooks version, the state of the rendered UI depends on ephemeral events and the order they were dispatched. The hooks version is more easily tested and it's easier to reason about as a developer. It conforms to the mental model of a function (props, state) => UI. The no…

This pattern (event -> state change -> effect run) is finally advised against in the new React docs: https://beta.reactjs.org/learn/you-might-not-need-an-effect

See "You don’t need Effects to handle user events".

Re: React is holding me hostage

#454
post #70

Earlier quoted context omitted.

None of that is true in React hooks. The negative sentiment towards hooks that you see here is because it is weird and complicated. Want to see how much simpler code can get when you code without React or any such fat frameworks? Take a look: https://github.com/wisercoder/eureka/tree/master/webapp/Clie... You just need to know JavaScript, HTML and CSS, not much else. The code is simple, and yet maintainable. No need…

https://github.com/wisercoder/eureka/blob/master/webapp/Clie... I love how you do React. I mean, what's more react-y than blanking the page then appending HTML? I'm gonna call that Rejqueryact, because it's jQuery inside React.

I'm not seeing React being used, though, just TSX/JSX? All the view and state updating is being done manually, but it looks fairly well-organised. There are small optimisations like debouncing onInput with a timeout (avoiding rapid re-rendering/reacting to every character typed): https://github.com/wisercoder/eureka/blob/master/webapp/Clie...

Is this really much more complicated to implement than the equivalent implementation in React? (It's probably a bit more responsive, at least.)

Re: React is holding me hostage

#455
post #368
post #212

Earlier quoted context omitted.

Try selling React shit to corporates who have corporate malware infested Edge running on overloaded Citrix nodes or the average corporate android that was made about 3 years ago. We still get And we actually can debug our product!

Both Discord and MS Teams use React (afaik) and only one of them runs shit. Both are not exactly light tho

Both of them run like shit in my experience. I mean Discord is basically mIRC that looks a bit better with a shit version of zoom strapped on the side.

Re: React is holding me hostage

#456
post #295

Earlier quoted context omitted.

Performance is obviously important, to suggest otherwise is just silly. Both Google and Amazon have researched this topic and the results are readily available. First link I found: https://www.thinkwithgoogle.com/marketing-strategies/app-and... Why do you think there some much time and effort going into improving performance of computing in general. Facebook Lite, android go, GPU's, cpu improvements, 5g, etc. The imp…

Arguing features vs performance is really about which features are more important. Performance is just another feature. I use Vim and I use VSCode. There is little debate about which has better performance and which has more features. It's also easy to see which has more users.

If you think Vim has less features than VSCode you haven’t used vim enough.

Re: React is holding me hostage

#457
post #421

Earlier quoted context omitted.

Jira is a not very good product, implemented by worse engineers, that happens to be better than its competitors (ironically proving the point I made further up thread).

> implemented by worse engineers Jira is a 20 years old piece of software. I'm sure today's engineers do their best with the constraints they have. And I'm sure the 2002 engineers did their best with this period's assumptions and solutions. I hate Jira as a product, but please don't attack people like that, have you never had to work on a product you're not 100% satisfied with? :/

https://www.atlassian.com/engineering/post-incident-review-a...

I stand by what I said.

>I’m sure todays engineers do their best with the constraints they have.

There are two real constraints in the software engineering world: time and money (especially when we’re talking about an issue tracker, a wiki and a repo + CI\CD pipeline).

That Jira and confluences performance remains … not very good, suggests that the engineers are unwilling to, or unable to advocate for, spending the time and money to address this.

Re: React is holding me hostage

#458

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…

This thinking is why most SPAs are utter shit for the end user. Most developers are so happy about their ergonomics and how cool their tools are and don’t care at all the application uses 200M on your browser and every key stroke takes 200ms to show in an input. This also happens in the backend, but the difference is that the company país the price in the form of more infrastructure. But in the frontend is “free” so…

that's a problem with the choice to go spa instead of ssr or static, not the choice to use a framework with productivity benefits. with every major meta-framework working seamlessly with the popular serverless hosts, it's a wonder anyone takes spa seriously in any performance-sensitive context

Re: React is holding me hostage

#459

Earlier quoted context omitted.

> When using React I usually just use MobX and everything just works. MobX is signals library. In other words, you are already using the signals way of doing things if you mostly manage your state with MobX. I still use MobX as well if I think I can't use SolidJS. SolidJs if you haven't looked has MobX-like tools built in, computed, autoruns and all the same tools, it triggers "renders" when one of the signals change…

I haven't used SolidJS, so I can't comment much. But Signals have very good developer ergonomics. But from my experience other frameworks that use them come with drawbacks that I don't get with react. So MobX+React works better for me than - let's say vue. From a brief look at their website, the downsides for using SolidJs for me seem pretty big. At the very first example, if you change it slightly you can see my pro…

There was a debate very recently between SolidJS and React communities over "internalized react-isms" like difference in behaviour you've pointed out. I think it's React that are doing the weird thing and calling your whole function again when one piece of data changes, but I do like having the ability to return early.

Re: React is holding me hostage

#460
post #295

Earlier quoted context omitted.

Arguing features vs performance is really about which features are more important. Performance is just another feature. I use Vim and I use VSCode. There is little debate about which has better performance and which has more features. It's also easy to see which has more users.

Is it vim in all 3 categories?

Just two of them.
Post reply on HN