JsMimeType PerlVar appropriately (use
PerlSetVar for a single new MIME-Type, or
PerlAddVar when you want to add multiple MIME-Types).
Given a choice, using
minify() function in that package.
Minification does require additional CPU resources, and it is recommended that you use some sort of cache in order to keep this to a minimum.
Being that you're already running Apache2, though, here's some examples of a mod_cache setup:
# Cache root directory CacheRoot /path/to/your/disk/cache # Enable cache for "/js/" location CacheEnable disk /js/
# Cache size: 4 MBytes MCacheSize 4096 # Min object size: 128 Bytes MCacheMinObjectSize 128 # Max object size: 512 KBytes MCacheMaxObjectSize 524288 # Enable cache for "/js/" location CacheEnable mem /js/
Graham TerMarsch (firstname.lastname@example.org)
Many thanks to Geoffrey Young for writing
Apache::Clean, from which several things were lifted. :)
Copyright (C) 2007, Graham TerMarsch. All Rights Reserved.
This is free software; you can redistribute it and/or modify it under the same license as Perl itself.