| ▲ | azangru 11 hours ago | ||||||||||||||||||||||||||||||||||||||||||||||
> Why do we code with React? ...is a loaded question, with a complex and nuanced answer. Especially when you continue: > it's worth paying the React complexity/page-weight tax All right; then why do we code in React when a smaller alternative, such as Preact, exists, which solves the same problem, but for a much lower page-weight tax? Why do we code in React when a mechanism to synchronize data with tiny UI fragments through signals exists, as exemplified by Solid? Why do people use React to code things where data doesn't even change, or changes so little that to sync it with the UI does not present any challenge whatsoever, such as blogs or landing pages? I don't think the question 'why do we code with React?' has a simple and satisfactory answer anymore. I am sure marketing and educational practices play a large role in it. | |||||||||||||||||||||||||||||||||||||||||||||||
| ▲ | simonw 10 hours ago | parent [-] | ||||||||||||||||||||||||||||||||||||||||||||||
Yeah, I share all of those questions. My cynical answer is that most web developers who learned their craftsin the last decade learned frontend React-first, and a lot of them genuinely don't have experience working without it. Which means hiring for a React team is easier. Which means learning React makes you more employable. | |||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||