Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

You want a component library like Tailwind UI: https://tailwindui.com/

You're right though that a lot of people who jump straight to tailwind probably don't realize that its low level might be too low for their needs. A higher level component library like bootstrap, tailwind ui, chakra, etc. is a better start in many cases.



I actually bought this quite a while back. It is nice, but a far cry from what developers typically consider components. In fact they are just HTML that you have to copy and paste. You have to build the interactivity yourself. I think they have recently started integrating them into some JS frameworks though possibly.


React and Vue are both coming, in case you haven't seen already: https://tailwindui.com/react-and-vue-support/


Ah, yeah component makers are in a hard spot right now. You can't really write a 'generic' component easily and have to take a bet on using whatever JS framework is in vogue--react, vue, etc. It's not easy for a react project to pick up a vue component and use it or vice-versa. Even ignoring the framework incompatibilities, it also requires your component users to now buy in to the whole bundler game.

You could work around this by sticking with a generic, simpler framework like good ole jQuery. But now your framework users in react, vue, etc. are mad that they need to pull in kilobytes of JS that's doing what their framework already does.

So... as a component author a bundle of HTML and bring your own logic is kind of the only low-level option that's ubiquitous. Things might get better with web components, but it's not all there yet.


Ionic approaches this problem with stencil. So the ionic components can be used by not only angular projects, but also react / vue / vanilla js


Maybe they're hoping the community creates the framework-specific implementations?


Yes thats the intent. They handle only styling and framework integrations are upto the community


Inspect element - copy and paste with the Alpine JS intact.


Thank you. That's all it seems to be to me, and when people say "look at these components", it seems like they've not seen value in vuetify, for example.


I have bought this, too. It's great.

There is also a “free” site, which offers lovely designs: https://tailblocks.cc/


I made a comment above, which got downvoted, but, I'll try to explain a bit more. Looking at tailblocks site ... it's just html/css (verbose tailwind). Having lots of markup for input boxes that don't have any affordance for validation states, aria tags - that's a lot of code in those example blocks that still forces me to have to add lots more stuff to get some basic interaction functionality that's already provided by other toolkits (which, again, all use a common base and therefor all are styled similarly without the need for a lot of boilerplate css).

Someone posted above that tailwindui(?) will be providing react and vue components - that may be worth investigating later. Possibly too late for some current projects, but I'll keep an eye out.


It might not solve your problem. It does solve problems for other people like me though.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: