3 ms·
Okay, I'm verrrry out of date with frontend dev, but didn't React used to be a framework? Now they're recommending you use frameworks? That are presumably buil
by EdwardDiego 2y ago
Okay, I'm verrrry out of date with frontend dev, but didn't React used to be a framework?
Now they're recommending you use frameworks? That are presumably built on top of React?
So what is React exactly these days? Feels like it's a shadow DOM renderer that's become a defacto API?
Like, you could use a component written for one React based framework, in another React based framework, and it'll just work?
Does React still provide routing and/or state management? Or has that been devolved to frameworks?
Wait a minute, has React become the J2EE of front-end?
- MarcelOlsz 2y agoReact is primarily for intimidating the piss out of new employees and flexing on your teammates with esoteric hooks and composables. In essence, React is the job security framework.
- sergiotapia 2y agoResume driven development driven to the absolute extreme. React is terrible
- invaliduser 2y agoNot primarily, as primarily it was just "we're the V in MVC", and people were using classes. The hooks came when the react team got on the "functional programming" wagon, and suddenly everything was about immutability, side effects, etc. and very little about giving control to the developers on their components life cycle.
- korm 2y agoReact was literally first created in ML out of the author's dislike of MVC, who preferred functional programming and immutability[0]. For a long time, react aspired for its future to be in ReasonML. Hooks came as no surprise to anyone who paid attention, as the recommended way to write components since at least 2016 was in the stateless functional style whenever possible, and many of us used recompose[1] to simulate hooks long before their introduction. [0] https://github.com/reactiflux/q-and-a/blob/master/jordan-walke.md https://github.com/reactiflux/q-and-a/blob/master/jordan-wal... [1] https://github.com/acdlite/recompose https://github.com/acdlite/recompose
- invaliduser 2y agoMaybe I was not paying attention, this is of course a possibility, but until at least early 2019 the react website's main page was only mentioning the class-based "stateful component" as the way to write components. https://web.archive.org/web/20190105060636/https://reactjs.org/ https://web.archive.org/web/20190105060636/https://reactjs.o... Although they were mentioning function components at the time in the documentation, I can't say how mainstream that was. Hooks were introduced in Feb. 2019.
- deleted 2y ago[deleted]
- _kidlike 2y agoand yet, every time I have a discussion about this with my frontend colleagues, they are soooooo far gone into the React pill, that it's impossible to talk to them. And they all happily migrate from one hype to the next, as the React gods dictate, burning funds for no reason. Funnily enough, the more time passes, the more bugs and regressions our frontend has.
- lakomen 2y ago[dead]
- gcau 2y agoReact has never been a "framework", it's a "view library" that can be included in a framework. The benefit is you can pick your own pieces, like building your own computer. Also, React doesn't handle routing (I recommend wouter), and yes it does state management (I recommend zustand for additional state management). You seem pretty opinionated on something you don't know a whole lot about.
- rahkiin 2y agoYour opinions here are the core of my gripe with React: everybody has their own favorite package for some functionality that comes in standard frameworks. You’re mentioning libraries I didnt know existed. This makes every react app different, annoyingly for docs, help resources, and people. No surprise NextJs gets more popular
- kouroshp 2y agoReact itself was never a framework, just a library to render user interfaces. Routing, data fetching etc. have always been separate libraries (or built into frameworks).
- esperent 2y agoThis way of stating things leaves out the central position that React has in any setup. You'll always be using a React routing library, a React data fetching library, a React state management system, and so on.
- TiredOfLife 2y ago> You'll always be using a React routing library, a React data fetching library That's like saying "you will always use js in backend" while ignoring every other backend language.
- floydnoel 2y agodevelopers often want those things, but they are certainly not required. i certainly don’t use a react data fetching library, i just use fetch. i don’t use special react state management, just use redux. i did build a router that works primarily with React in order to support JSX in the components, but it wouldn't be any harder to adapt it to another framework or setup. the problem is exactly the same as those memes making fun of people asking on stack overflow "how do i add two numbers with jQuery?" eg 'how do we add two numbers with React' the problem is there are always new developers making silly mistakes, and making that an indictment of some technology is a fallacy.
- deleted 2y ago[deleted]
- EdwardDiego 2y agoIt wasn't like that when it first came out, from my experiments with it when it was first released.
- 0x1ceb00da 2y ago> I'm verrrry out of date with frontend dev How many days?
- EdwardDiego 2y agoWhen was JQuery winning against Mootools and Prototype etc.? Roughly that many days.
- askonomm 2y agoYeah, I was around back then, and the difference from then to now is equivalent to the difference between inventing the wheel and going to the moon. Not necessarily in a good way.