Skip to content

Allow generation of unminified CSS file#195

Merged
oliverandrich merged 3 commits intodjango-commons:mainfrom
treyhunner:allow-unminified
Apr 10, 2026
Merged

Allow generation of unminified CSS file#195
oliverandrich merged 3 commits intodjango-commons:mainfrom
treyhunner:allow-unminified

Conversation

@treyhunner
Copy link
Copy Markdown
Contributor

I am switching to django-tailwind-cli from an npm-managed version of Tailwind and I'd like to keep using the unminified CSS file I generated before, as I sometimes like to scroll through the diff and ensure sensible classes were generated (I minify later on in my asset pipeline).

This would:

  • Add a TAILWIND_CLI_AUTOMATIC_MINIFY setting that can be set to False to disable minification
  • Add a --minify and --no-minify flag to override that setting

I am open to alternate names if you feel TAILWIND_CLI_AUTOMATIC_MINIFY is too verbose or alternate implementations (like allowing --no-minify but not allowing customization via a setting).

@oliverandrich
Copy link
Copy Markdown
Member

This is a good addition and a great idea. I looked into the pull request and merged it. I expect to release it on the weekend in a new version. I have to make up my mind, if I want to merge another feature into the release or not.

Thanks for the contribution.

@oliverandrich oliverandrich merged commit 7c64448 into django-commons:main Apr 10, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants