]> iEval git - plack-app-gruntmaster.git/blame_incremental - JS.pm
fixed "Page 1 of 0" in job log
[plack-app-gruntmaster.git] / JS.pm
... / ...
CommitLineData
1package Gruntmaster::Page::JS;
2
3use Gruntmaster::Page::Base;
4use JavaScript::Minifier::XS qw/minify/;
5
6sub generate{
7 my ($self, $format, $env) = @_;
8 debug $env => "";
9 my $js;
10 $js .= read_file $_ for <js/*.js>;
11 [200, ['Content-Type' => 'application/javascript', 'Cache-Control' => 'public, max-age=604800', 'X-Forever' => 1], [minify $js] ]
12}
13
141
This page took 0.024415 seconds and 5 git commands to generate.