To include a copyright comment at the top of the minified code.
minify(input => 'var x = 2;', copyright => 'BSD License');
minify(input => 'var x = 2;', stripDebug => 1);
The "input" parameter is mandatory. The "output", "copyright", and "stripDebug" parameters are optional and can be used in any combination.
The ECMAScript specifications allow for many different whitespace characters: space, horizontal tab, vertical tab, new line, carriage return, form feed, and paragraph separator. This module understands all of these as whitespace except for vertical tab and paragraph separator. These two types of whitespace are not minimized.
Exported by default:
You may also be interested in the CSS::Minifier module also available on CPAN.
Peter Michaux, <email@example.com> Eric Herrera, <firstname.lastname@example.org>
Copyright (C) 2007 by Peter Michaux
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.6 or, at your option, any later version of Perl 5 you may have available.