Component Library.

I've been thinking of making our own component library for our company. At the moment we style stuff with Material UI and we're moving over to tailwind. If I were to make such library should I take the path or architecture that Daisy UI uses ? Or is there an example that anyone feel fits better for an scalable library solution?
10 Replies
Unknown User
Unknown User2y ago
Message Not Public
Sign In & Join Server To View
robotkutya
robotkutya2y ago
What do you mean by the path / architecture that Daisy UI uses? --> complex utility classes (e.g. btn) ? If it's for your company, and you guys have a design system that a designer actively maintains, then you probably don't want this approach. What worked very well for us (small team), is 1) designer builds design system inside FIGMA 2) we export the design tokens from figma via a JSON 3) we import said tokens into our tailwind config via a script 4) build components with headless-ui (alternatives include radix, aria-kit, react-aria...) building a good component library is a loooooooooooot of work, like thousands of hours lots of work so I would build on top of existing headless libraries
robotkutya
robotkutya2y ago
Working with Tailwind CSS - MUI Base
Learn how to style MUI Base components with Tailwind CSS.
robotkutya
robotkutya2y ago
but the DX is pretty bad, the linting for example doesn't work out of the box, you have to add your own regexp rules to intellisense... meh... I'm not a fan and we do use storybook, because my designer knows how to code, and storybook provides a nice sandbox for him to play around in, we can add some documentation there as well
Nestor
Nestor2y ago
Yeah, current issue is that we don't. So basically we make the styles ourselves and management want us to move from MaterialUI (which I agree) But they want us to make a library of reusable components, with Storybook attached. I agree with you guys that maintaining it is super hard I bring up DaisyUI because it seemed like the most straight forward way of not tying logic to styles and having the less amount of code as possible Because I would like, as well, keep using headless libraries I wonder if I can make a package that imports into our tailwind config and we can load said styles that way
Unknown User
Unknown User2y ago
Message Not Public
Sign In & Join Server To View
robotkutya
robotkutya2y ago
this can mean a lot of things, so maybe a good direction is to talk to them, what they want and why? If you don't have a designer working with you, then it's kind of a bad idea to build your own design system and component library I'd push back and discuss
Nestor
Nestor2y ago
Yeah, me too Also we're very small as well I must add
Unknown User
Unknown User2y ago
Message Not Public
Sign In & Join Server To View
Nestor
Nestor2y ago
Yeah, I'll make a brief for next week, and discuss it again Since this has been stopped for months now Also my team agrees with me that we might not want to just "copy paste" some of our components lol The whole idea of having sort of like TailwindUI seems pleasing as well
Want results from more Discord servers?
Add your server