yogthos / lein-asset-minifier

Leiningen plugin for CSS/Js asset minifcation
Eclipse Public License 1.0
41 stars 7 forks source link

Multiple targets option #17

Open ericdallo opened 6 years ago

ericdallo commented 6 years ago

There could be a way of create multiples targets with the same source file, so i will not have a big file with all js, and i only need to import in my html the file that i want. It will only minify the file, not group all files in one.

Something like this example:

:minify-assets [[:js {
    :source ["source/"] 
    :target "target/",
    :pattern "*.min.js"}]]

from:

source
├── login.js
└── home.js

to

target
├── login.min.js
└── home.min.js

What do you think about it?

yogthos commented 6 years ago

That looks reasonable to me, would you be up for doing a PR to add the feature?