Server-side auto-minify?

前端 未结 4 479
不知归路
不知归路 2020-12-31 10:02

Is there any way to automatically minify static content and then serve it from a cache automatically? Similar to have mod_compress/mod_deflate work? Preferably something I c

4条回答
  •  春和景丽
    2020-12-31 10:10

    If you use Nginx instead of lighttpd then you can take advantage of Nginx's embedded Perl support to leverage the Perl module JavaScript-Minifier to minify and cache JS server-side.

    Here are the details on how to achieve this: wiki.nginx.org/NginxEmbeddedPerlMinifyJS

提交回复
热议问题