5 ms·
For almost 10 years, the core react developers would repeat incessantly: React is a library, not a framework. In the past 2 or 3 years, they just "gave" up, tu
by meiraleal 2y ago
For almost 10 years, the core react developers would repeat incessantly: React is a library, not a framework.
In the past 2 or 3 years, they just "gave" up, turned it into the biggest most bloated framework in the frontend area while the official Web APIs in the browsers evolved so much that React is actually completely useless and now it is completely useless with a compiler.
I'm wondering if that was actually the reason they pivoted to this Frankstein? The loss of relevance as a frontend library.
Anyway, I jumped off the bandwagon and don't have a say in this fight anymore. But I'm doing my part advising every Junior Developer to not make the mistake of choosing React today.
- tuyiown 2y ago> advising every Junior Developer to not make the mistake of choosing React I don't like react much, but I surely hope you advise them on ways to organise state management and rendering with good ways to track event listeners.
- naught0 2y agoReact is the premier frontend framework because it is easy to learn, scales ad infinitum, and has reached a critical mass where the library support is second to none. Anyone advising juniors against learning React is shooting them in both feet, not least because of the demand for React developers.
- ttfkam 2y agoLearn JavaScript first, then React. Far too many devs know the React APIs without any context. If you know JS/TS, any framework is learnable. If you don't, your React code will never improve past mediocre and bloated. Strong foundational knowledge in HTML and CSS helps as well. Still amazes me how many folks put onclick handlers on div tags and freak out when margins collapse.
- TonyAlicea10 2y agoFundamentals before frameworks. I've been a tech educator for a decade now, and still see this so much.
- mitemte 2y agoIs React irrelevant? Stack Overflow’s 2023 developer survey places it first overall for web technologies [1]. I’ve always considered React to be one of the more straightforward front end libraries, so it’s surprising to hear it being called bloated. 1. https://survey.stackoverflow.co/2023/#section-most-popular-technologies-web-frameworks-and-technologies https://survey.stackoverflow.co/2023/#section-most-popular-t...
- deleted 2y ago[deleted]
- ttfkam 2y agoThe fact that you have to go to often heroic measures to keep your bundle size under 500KB even for simple apps doesn't make it irrelevant or useless. It is indeed bloated: on the development boilerplate side, the bundling/deployment side, and the browser runtime experience. With an experienced and top-notch developer, anything is possible in any language or framework. For the other 95% of devs out there—especially on a team where the lead doesn't keep a strong grip on the reins—React turns to mud awfully fast. But it's mud with an extensive ecosystem and tons of inertia helping it succeed.
- plazma 2y agoYou nailed it, this is exactly my experience.
- neolefty 2y agoThe worst library except for all the others? The complexities are there for good reasons IMO; I also like React — and I look forward to the compiler allowing simpler code.
- azangru 2y ago> Is React irrelevant? Stack Overflow’s 2023 developer survey places it first overall for web technologies Consider jQuery. It was extremely popular once; was super influential to the point that some of its apis were adopted by the browser; is completely irrelevant now; but is taking a long time to die. I've been wondering whether React is destined to repeat this trajectory.
- afavour 2y agoI strongly dislike React (not to be a hipster but I have for years!) but I wouldn’t advise junior developers avoid it. Like it not React is still the de facto standard, if I tell someone who doesn’t know better to avoid it I’m harming their career.
- meiraleal 2y agoNo, you are not. The complexity of a React app is pure madness. The bloat in the ecosystem of (mostly) abandoned packages is unparalleled. With the bloat comes the need to tree-shake, bundle, compiling, things that are not needed in modern web development but takes a good amount of the dev cognitive load when developing a React app. There are great alternatives nowadays that don't come with the bad recent decisions of React: Solid, Lit, even vue or svelte.
- afavour 2y agoAs you may recall I said I strongly dislike React. You are preaching to the converted with your complaints. That does not alter the fact that junior developer needs to know React since for better or worse (worse) it is the de-facto standard for front-end development at the moment.
- meiraleal 2y agoI’m discussing tech, while you’re discussing anthropology. Should people use an inferior tool to achieve a higher social status/paycheck? I don't know, that's your opinion. Do I recommend someone learn React to develop a web app nowadays? No, it's not worth it. I'm not preaching to you, but to the juniors reading the thread. React contributes significantly to current JavaScript fatigue, and supporting it so juniors can get a job isn't in my or their best interest.
- afavour 2y ago> I’m discussing tech, while you’re discussing anthropology I’m discussing career advice. Something junior developers look to senior developers for. If your advice to your juniors results in them having fewer employment opportunities then you’re not doing a good job as a mentor. > Do I recommend someone learn React to develop a web app nowadays? No, it's not worth it. In what way is it not worth it? The majority of front end dev is done in React. Of course it’s worth it, even if it’s shitty.
- vasergen 2y agoI am not a front-end developer. What are better alternatives to React nowadays?
- ttfkam 2y agoDepends on your goals/focus: Smaller, cleaner, and faster code while still focusing on dynamic interfaces? Svelte or SolidJS Focus on server-side HTML rendering with little to no browser dynamism? PHP (It really is quite nice now.) Focus on server-side HTML rendering with some browser dynamism? HTMX + server framework (PHP, Django, Go templates, etc.) Getting a job as quickly and easily as possible, especially at larger companies? React or Angular (You're a cog in the machine, but cogs often get better paychecks to deal with multi-megabyte code blobs.) Can't decide between code elegance/performance and finding a job, so you're willing to compromise a little on both? Vue
- whalesalad 2y agoVue 100%
- neolefty 2y agoReact really is pretty good as long as it keeps evolving. Innovations tend to come from new frameworks such as Svelte and SolidJS, and then React adopts them — this new compiler is an example. React is hobbled by the need to retain backward compatibility, but it is boosted by sheer scale and a solid underlying philosophy, design, and engineering. Someday, we will probably find a fundamentally better philosophy for UI frameworks, but I don't know yet what it will be. React replaced its MVC predecessors with a functional approach, the Flux model.
- nox101 2y agoLit? AFAICT, if you pick any of the others options you'll have to refactor your site every 3-4 years as all the tools bit rot. One won't run on the latest version of node so you upgrade node. Now 2 other libraries fail and require an upgrade. Now another library fails because it's not compatible with those upgrades, repeat. You thought you were just going to fix a bug or add a small feature that would take you a few hours but now you've got few days/weeks of refactoring before you can even start.
- dimmke 2y agoI jumped off and started using Svelte but have now found looking at job listings all the non tech companies are still using Angular and all the startups/tech centric companies are using Next.js. I feel like from an employability perspective I shot myself in the foot, but I also dislike both of those frameworks. So maybe I should just quit being a front-end developer and try to retrain as something else.
- ttfkam 2y agoI like Svelte too, but take another look at Angular. Your memories of Angular 9 don't match up anymore. It's A LOT more streamlined now with so much less boilerplate than before. And signals. That said, transitioning to some backend or infrastructure focus never hurt anyone. It's good to see problems from different perspectives and roles. No one ever got fired for knowing too much SQL.
- willsmith72 2y agoIt's just a frontend framework. If you already have fundamental web dev knowledge, you'll be able to switch between them easily. That's why I like Remix. It's react + web fundamentals. I'm happy to jump into a Vue, svelte, angular project. It's not all that different
- dimmke 2y agoYeah, obviously however if you don't have previous experience with a framework in your résumé, they're going to choose the people that do.
- rafark 2y ago>For almost 10 years, the core react developers would repeat incessantly: React is a library, not a framework. I always disliked the it’s a library not a framework debate. Isn’t any library a framework, technically?
- erik_seaberg 2y agoYou call a library as you see fit. A framework calls you.
- recursive 2y agoOh yeah. I guess that's why we always invoke function components directly. Because it's a library. /s
- throwAGIway 2y agoWhat do you think you're doing when you call render(<App />,...)?
- recursive 2y agoNot calling App. Creating a react element with a reference to the function. The reconciler will call it later, asynchronously. Put in some console logs and see the order of operations for yourself. Also, try calling App and see what happens if it uses hooks.
- throwAGIway 2y agoThe createElement function is called immediately, and it immediately calls your component function. I don't think this is a significant difference. Many libraries accept a callback and I'm really not ready to call all that a framework just based on that.
- recursive 2y ago