DEV Community

Clarice Bouwer
Clarice Bouwer

Posted on

1

Dynamically execute Tailwind CSS on multiple files with multiple outputs

Finds all CSS files in a given director, iterates through them and executes tailwindcss CLI using the Tailwind config and outputs each file to a dist/ dir.

find . -name \"*.css\" -exec npx tailwindcss -c tailwind.config.js -i {} -o dist/{} \\;
Enter fullscreen mode Exit fullscreen mode

Top comments (1)

Collapse
 
melroy89 profile image
Melroy van den Berg

-c option is no more in Tailwind v4 ;(

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more