5 ms·
Who do you feel React is hurting, and in what way?
by wbobeirne 4y ago
Who do you feel React is hurting, and in what way?
- ramesh31 4y ago>Who do you feel React is hurting, and in what way? There's an entire open source community that revolves around "React alternatives that exist because they're not React". For better or worse, people have ideological reasonings for their choice of JS framework. I've seen it play out countless times at multiple jobs between people who just want to get their work done with the industry standard tooling, and people who have a bone to pick with FB and become fanatical about using Vue/Svelte/*whatever instead of React. The contrarians usually win out, because the people who just want to do their job and go home don't care enough to fight that battle over and over again. The result is a patchwork of forgotten projects and frozen dependencies that no one knows how to maintain, and a security nightmare where everything is pulling in tons of random unmaintained NPM packages with 4 GitHub stars, rather than the battle tested 5 year old React equivalent with 2k stars.
- bornfreddy 4y ago> ...and a security nightmare where everything is pulling in tons of random NPM packages with 4 GitHub stars. To be fair, this happens with React too (all the time). It has more to do with the JS ecosystem than with the framework of choice.
- cercatrova 4y agoThis is exactly why I use React after using libraries like Vue. The ecosystem matters, and non-React libraries are simply just not there. I want to make stuff, not wrangle around with poorly-supported dependencies.
- qwertox 4y agoMy biggest issue with React is how it mixes HTML in Javascript. Like putting HTML inside strings or whatever they are doing. Without proper tooling and an editor which supports it, you won't get anywhere. At least that's my amateurish feeling on React, my reason for avoiding it. I may very well be wrong, but I wouldn't know.
- woah 4y ago> Like putting HTML inside strings or whatever they are doing. That's exactly what they're not doing
- cercatrova 4y agoYou'd be wrong. JSX is just syntax sugar over manipulating nested JS objects which represent the state. Try React sometime, their docs are great: https://beta.reactjs.org/ https://beta.reactjs.org/
- Ambroos 4y agoOf all the ways to write how your HTML is supposed to look from JavaScript, JSX is probably the closest to Javascript there is. It's a very simple syntax translation to JS function calls, and all code / logic is still plain JS. Every other template language that invents their own loops / conditionals / ways to insert variables is waaaaaaay further away from JS (and also still needs tooling and editor support).
- itslennysfault 4y ago... or don't write how your HTML is supposed to look from JavaScript. I like Angular's approach the best. You have an HTML file, a SCSS file, and a TS file. The TS file is essentially your model and handles all the thinking. HTML/SCSS are kept declarative like god intended.
- Ambroos 4y agoDo you genuinely think Angular's template language and all the complexity it comes with is better than JSX just saying "anything between {} is plain JS"?
- itslennysfault 4y agoAgreed. React reminds me of early days PHP. Which I supposed makes sense from an engineering org that was birthed on PHP. Separation of concerns?? NAHHH!!