Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
725 views
in Technique[技术] by (71.8m points)

tailwind config build tools in monorepo

So we want to start a new project having a monorepo with every component as a separate project. i.e.

App (repo)
-- Button (project)
-- -- package.json
-- Radiobutton (project)
-- -- package.json
tailwind.config.js

What we'd want to do is having a single tailwind config and be able to have a build per component run through the main package.json in App. So that we minimize the css classes left in Button for instance.

Basically a css class should be generated for Button containing only the classes used there. Similarly it would happen for RadioButton having everything completely separate.

Has anyone got an idea of an approach to this? I can find info on monorepo's but not in combination with tailwind specific covering multiple projects given that we don't want to have a config file in each project.

Output would then be:

dist/App
-- Button
-- -- Button.jsx
-- -- Button.css
-- Radiobutton
-- -- Radiobutton.jsx
-- -- Radiobutton.css
question from:https://stackoverflow.com/questions/66046889/tailwind-config-build-tools-in-monorepo

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...