Re:Tailwind UI
by ec109685 on Wednesday February 26, 2020 @12:28PM
(#22425125)
Your components often get bloated since you have to account for subtle business logic differences between views.
[ Parent
| on HN ]
Re:Tailwind UI
by stefanfisk on Thursday February 27, 2020 @12:19AM
(#22430741)
Isn't that what the container/component split is for? Presentation logic in a container, markup and styling in a component. If you need to reuse the same visual component in logically different contexts you create a new container that mangles the props as appropriate.
Yeah, you can. I've just seen this result in really complicated components. Other styles of CSS naturally separate presentation from html markup generation, so the cost of forking and specialized components is much lower.