React isn’t just "winning by default" It's winning because at the core it's just JavaScript function composition. A component is a function, conditionals are `if (...) { ... } else { ... }`, loops are `map()`. JSX is just sugar for function calls. In Svelte you are writing XML with little JavaScript islands inside it. Instead of if you get `{#if}{:else}{/if}`. Thats not "ergonomic" – thats a mini-language stapled on…
So JSX is pure Javascript and not, say, a dialect of XML embedded in JS? Because it sure looks like the former even though it compiles to the latter. React isn't Javascript. It's a franken-language that looks superficially like a mix of JavaScript and XML whilst following the rules of neither. That's why there is such a thing as a React compiler - a good sign that you're not writing JS, which doesn't have compilers.…
React is winning by default and slowing innovation
671–680 of 866 posts
Re: React is winning by default and slowing innovation
#672I feel this with every fiber of my being. I used to do a TON of front-end work, some of it quite cutting edge, delivering highly performant user experiences in the browser that had previously been only thought possible in a native app. Back in like 2009-2015. I was deeply connected with the web standards fundamentals and how to leverage them mostly directly. I detoured into heavier focus on backend work for quite a w…
>You still get JSX Give me S-expressions instead. How else am I supposed to prove to frontend developers that I didn't make those up
Re: React is winning by default and slowing innovation
#673Re: React is winning by default and slowing innovation
#674Earlier quoted context omitted.
The same is true everywhere in tech, I swear. "What if we abstracted away X?" My dude, you're already operating on like five levels of abstractions, and you haven't the slightest clue how any of them work. The answer isn't another abstraction, it's learning how computers actually operate.
I once worked on a VK mini app with one guy. He was building the app itself, I did the backend. He just recently started learning web development, having never done any programming before. So I'm ready for him to test my backend, I tell him to make a request to https://... and pass this and that parameter. And he just has no clue what I'm talking about . He somehow managed to learn React, a bit of HTML and a bit of C…
Re: React is winning by default and slowing innovation
#675Earlier quoted context omitted.
React gets reinvented every year? Are you talking about functional components instead of class components? What big changes am I missing here? It seems pretty static to me.
Maybe they are, I can't speak for them but I've noticed that React hasn't been "reinvited every year" since maybe, 2019 or so, whenever we changed from functional components to class components and then back to functional with hooks. My feeling is that people who have been devving in react post-all-that-nonsense are living in the new world of a much more stable framework that does have new things coming in (Server Co…
Re: React is winning by default and slowing innovation
#676An engineer designs solutions. That includes selecting the right tools.
Re: React is winning by default and slowing innovation
#677Earlier quoted context omitted.
Webapps were a mistake :(
The frustrating part is that the idea is incredible. Everyone has this piece of software on their computer that lets them run anything as long as there is a server to talk to. I love it. I don't want to have to download a thousand apps, especially not for shopping or banking. Just using a web interface is awesome. Unfortunately we decided the correct way to provide the functionality was by layering bonkers ass abstra…
I use inline styles mostly, with an external CSS file only used for a few very global styles. And I try to only use it very simply, avoiding all kinds of clever tricks that some dev think is the mark of good code.
Re: React is winning by default and slowing innovation
#678I'm not a front end dev and only use JS stuff time to time for small personal project. There is so much JS framework out there that appear and disappear so fast. I don't know if we can call it innovation. I have the impression they just reinvent the wheel with so little value added. I prefer to keep on React at least it will not disappear the next time I will do some change on my project.
It's really hard to be sure, but my pet theory is that frontend tech has been rapidly evolving since it had to solve some real problems that are relatively new at scale: - Work with reactive variables - Combine three different languages - Write modular code - Enable highly response designs The target platform (the web) doesn't natively support all of these things elegantly, and maybe for good reasons. I've got the fe…
Re: React is winning by default and slowing innovation
#679React isn’t just "winning by default" It's winning because at the core it's just JavaScript function composition. A component is a function, conditionals are `if (...) { ... } else { ... }`, loops are `map()`. JSX is just sugar for function calls. In Svelte you are writing XML with little JavaScript islands inside it. Instead of if you get `{#if}{:else}{/if}`. Thats not "ergonomic" – thats a mini-language stapled on…
> React isn’t just "winning by default" It's winning because at the core it's just JavaScript function composition. A component is a function, conditionals are `if (...) { ... } else { ... }`, loops are `map()`. JSX is just sugar for function calls. I agree with JSX, and function components are nice, but React is most definitely not just function composition. Hooks add state and introduce life cycle events that take…
When your just using vanilla react, I've never had a problem with hooks being that hard to reason about. Once you add in SSR, routers, query caching frameworks, etc the "lifecycle & state" starts to get confusing.
This is mostly a problem with the additional complexity of these frameworks (nextjs, tanstack) and not react at its core. Building an app with just react (and maybe redux) feels so simple and natural once you learn the paradigm.
Re: React is winning by default and slowing innovation
#680Earlier quoted context omitted.
My pet theory is that frontend devs have so little on the critical path, and are usually overqualified for the kind of work they do, that they keep reinventing these interesting paradigms for managing state in GUIs basically just so they can keep themselves entertained.
You are giving most front end devs way too much credit. Most just use React because that's what they were taught and see it as an end rather than as a means to an end as if it is an accomplishment. Computers have become faster while websites have become slower. You can go on a random webpage and usually see 100s of MBs of memory being used while we had computers in the 90s running 3D games with around 1/100 of that.…