Using different resources to style pages #

For styling HTML/web pages, can we use different libraries/resources at the same time? For example, we may like to use navbar from bootstrap and use tailwind CSS to style other components and at the same time use pure CSS for other components on the same page. Will this be possible or will it create conflicts?
8 Replies
Jochem
Jochem3d ago
yes, it's possible. And yes, it probably will create conflicts, especially combining bootstrap and tailwind. you can combine either with vanilla CSS without any issues though, and very likely always will ( or at least should in the case of Tailwind)
Raheel
RaheelOP3d ago
What about pre made components provided by UI libraries like Daisy UI, material UI or Ant Design? Can i fetch different components from different libraries at same page?
Jochem
Jochem3d ago
It Depends™️ If there's colliding class names, especially if your framework doesn't scope its css, there'll be issues. But a lot of the time it'll probably work?
Raheel
RaheelOP3d ago
Thanks for helping out. I have faced issue of conflict between bootstrap and tailwind.
Jochem
Jochem3d ago
I imagine so, they've both got a ton of utility classes with obvious names
ἔρως
ἔρως3d ago
mixing ui frameworks is a shortcut for disaster not to mention the bloat avoid it at all costs
Raheel
RaheelOP3d ago
But sometimes while using UI libraries, we don't get desired components from a single source. We have to use components from different sources. In such case, will there be conflict? I am not referring to bootstap and tailwind in this case. I am taking about pre-built components.
ἔρως
ἔρως3d ago
probably, you cant know until you try if you need specific components, try checking shadcn
Want results from more Discord servers?
Add your server