3 ms·
95% of what you said has nothing to do with JSX, and most of it would apply to any good framework, so its not even react-specific. Why do you thing that a spec
by SahAssar 3y ago
95% of what you said has nothing to do with JSX, and most of it would apply to any good framework, so its not even react-specific.
Why do you thing that a specific syntax for writing createElement gives all these positives?
What do you think all of this renders down to? That's right, html, js and css. So if those are not properly standardized and working then your house of cards falls no matter how well you have built it.
- solardev 3y agoJSX is the first major JS component ecosystem, which spawned builders like webpack and with them easy polyfills and linters. The standards are thus enforced during dev and build, then polyfilled or transpiled to whatever you need, whether that's different browsers or even native, etc. The underlying HTML no longer matters except to the lib maintainers.
- SahAssar 3y agoJSX is not a "component ecosystem". JSX is a way to embed HTML-like syntax in JS and convert that to function calls. It does not grant any additional capabilities besides letting you write `<div>` instead of `react.createElement('div')` or `div()` or `h('div')`. Are you actually meaning react when you say JSX? Builders, polyfills, linters, components, frameworks, etc. existed before and exists independently of JSX and react. > The underlying HTML no longer matters except to the lib maintainers. Would you hire a frontend dev that didn't know the difference between a <head> and a <body>? A <input> and a <select>? Even if you would (which IMO is a very bad idea), the only reason you can build anything is that there is a well standardized base, which consists of HTML, JS and CSS. If those where not as stable, standardized and consistent as they are you would not be able to build rich web apps on top.