top | item 46690762

(no title)

danabramov | 1 month ago

For what it’s worth, the point of React is that you can just fix that Radio component to be an input (if that makes sense) and it’ll just be an input.

React gives you boxes to put stuff into but you decide what to put into them. Then React ensures that you can change what’s in those boxes without breaking anything. That’s the power of component abstraction.

discuss

order

jagged-chisel|1 month ago

> That’s the power of component abstraction.

Yes. But React isn’t the only way to do components. Unfortunately, to the inexperienced, it is.

nine_k|1 month ago

What are some much better ways to do components?

React with is so prevalent because it's a deep local optimum.

fsniper|1 month ago

So is a span or div element? What am I missing here?

daveidol|1 month ago

The parent comment is seemingly blaming React for the decisions of Shadcn for some reason.

There’s nothing about React that requires you to overcomplicate your DOM (unlike many other UI frameworks).