17 ms·
> component per-file React app Nothing in React requires to have one component per file. And you can do the same with jQuery or vanilla JS. > equally arbitrar
by dsego 6y ago
> component per-file React app
Nothing in React requires to have one component per file. And you can do the same with jQuery or vanilla JS.
> equally arbitrary CSS file
Something makes programmers, who are usually very opinionated about their code architecture & patterns, to just throw it all away and just pile on shitty css code. It's almost as if they don't actually put any thought into it. Could it be that their Java code patterns just cargo-culting and they don't truly understand it? That can't be it, something else?
> React is readable with HTML, JS, and CSS all right next to each other
React has JSX, not HTML. And nothing requires CSS to be in the same component or file. It's still just an organizational issue.
- somethingAlex 6y agoI'm not speaking strictly, I'm simply alluding to the fact that it's very easy to organize React projects such that its obvious which HTML the JS and CSS is scoped to. Pragmatically, I have not found that to be the case in projects which use jQuery.