Minify support wildcards?

minify seems handy almost an equivalent function of nginx pagespeed module’s filters for minification etc :slight_smile:

would it support wildcard paths ?


minify  {
    only */js/jquery

so any directory url containing /js/jquery ? like /js/jquery and /blog/js/jquery would both match ?

(Pinging @hacdias)

If @hacdias wishes, an easy way out is to integrate if conditions and something like if {path} ends_with /js/query will be possible.


I like the @abiosoft idea! What do you think?

if {path} starts_with /sth/
if {path} ends_with /sth.js
if {path} is /sth/sth.css
1 Like

@hacdias you can look at setup.go file for redir to see how to integrate it. Feel free to ping me if you have any questions. :slight_smile:


Sure, thanks! :smiley:

Hey @eva2000,

I’ve made some updates to caddy-minify and now it supports if and if_op and I’ve removed my own directives. If you want to run it right now, you have to build Caddy from source. Then, check the new syntax here. It will be available on in undetermined time (c.c. @matt).

:smiley: Thanks for having this excellent idea!

1 Like

@hacdias thanks for the heads up - this will be useful :slight_smile:

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.