timdaub pfp
timdaub
@timdaub.eth
honestly React Hooks and JSX are so fucking annoying. Just let me use god damn JavaScript for fucks sake. All this extra magic with useEffects, new syntax and producing incompatibilities with the regular JS event loop model is soooooo confusing. I now notice because I'm using nodejs a lot where everything is consistent
12 replies
1 recast
5 reactions

sean pfp
sean
@swabbie.eth
I think we can all agree that JavaScript is shit & TypeScript only slightly helps and the world would be a better place if everything was written in Go and Python. But alas, that's not the world we live in, and JavaScript is the collective browser religion, so I think React is pretty damn good given the circumstances.
1 reply
0 recast
0 reaction

timdaub pfp
timdaub
@timdaub.eth
JS is a great programming language. The problem is FAANG. The problem are the morons writing web APIs and frontend frameworks - but the JS core itself is awesome! So it is Google with web API blunders enforced by Chrome and everyone else with too much reach doing frameworks but bad paradigms like Meta
1 reply
0 recast
0 reaction

dinislam pfp
dinislam
@dinislam.eth
you could write html + js (or jquery or whatever), is there something you’re using that requires you to write React?
1 reply
0 recast
0 reaction

timdaub pfp
timdaub
@timdaub.eth
I actually wanted to but the wallet selection picker scared me and in general there doesn‘t seem to be much tooling for non react web3 stuff. But yeah I‘m seriously considering removing it. I‘m anyways using it like jquery to reduce jank ATM https://github.com/attestate/kiwistand/blob/main/src/web/src/main.jsx
1 reply
0 recast
1 reaction

dinislam pfp
dinislam
@dinislam.eth
Totally. There's broad consensus that React (or more generally libraries that derive UI from state) is _the_ way to do webdev. I think if you go along the jquery route for long enough, you'll probably come to the same conclusion :)
1 reply
0 recast
1 reaction

timdaub pfp
timdaub
@timdaub.eth
meh
1 reply
0 recast
0 reaction

Gabriel Ayuso pfp
Gabriel Ayuso
@gabrielayuso.eth
I'm on the same boat. I just learned react earlier this year and the hook and state loop stuff was so confusing and counterintuitive. I got used to it but it took a while. For request I ended up string trigger callbacks to all hooks so I could have control of when the hook was called instead of the weird loop.
1 reply
0 recast
0 reaction

timdaub pfp
timdaub
@timdaub.eth
It‘s very strange and the problem is they break basic JavaScript guarantees such that suddenly you can only do a few things in a component. It‘s also strange why they‘d chose such a paternalistic approach. I truly know what I‘m doing, they don‘t need to teach/limit me 😄
1 reply
0 recast
0 reaction

sean pfp
sean
@swabbie.eth
The power of modern programming is the ability to leverage the work of so many others so you don't have to "reinvent the wheel," especially for things like frontends where it is highly unlikely custom code is going to add any value to the business.
2 replies
0 recast
0 reaction

Gabriel Ayuso pfp
Gabriel Ayuso
@gabrielayuso.eth
Yeah I like React for that reason. It has really pushed the idea of reusable components more than any other previous attempts. It's still weird though lol
1 reply
0 recast
1 reaction

dinislam pfp
dinislam
@dinislam.eth
it was weird for me at the start, and now everything else feels weird :)
0 reply
0 recast
1 reaction