Good PHP-lib to compress js, css? -


i'm looking piece of php code compress js , css files requested. i've tried closure compiler , uglifyjs/uglifycss, few others. however, don't want install more software on server - basic lamp server should enough. therefor, want use php this.

i want able remove unneccessary whitespace (without putting code on row 1 - using newline characters instead of spaces better imo), comments, , minimize function- , variable names.

and yes, i'm sending js , css (and else) gzipped.

to expand on comments why js libraries shipped minified copies (jquery, bootstrap, etc).

development distributions available because provide ide's ability use content assistance, or perhaps because deployed straight source control repo.

some deployment processes (like assetic) go far compile entire directories of assets single minified files reduce page request time, think should follow suit on one. solution reduce download time @ expense of increasing server workload.


Comments