]> iEval git - gruntmaster-page.git/blobdiff - lib/Gruntmaster/Page/JS.pm
Import some changes from the mindcoding branch
[gruntmaster-page.git] / lib / Gruntmaster / Page / JS.pm
index 9e78192d0b12575b9107cf57f3207330da93c19b..f51000e85693665d81d3bcea6f5586fc1183c28e 100644 (file)
@@ -1,13 +1,6 @@
 package Gruntmaster::Page::JS;
 
-use 5.014000;
-use strict;
-use warnings;
 use Gruntmaster::Page::Base;
-our @ISA = qw/Gruntmaster::Page::Base/;
-our $VERSION = '0.001';
-
-use File::Slurp qw/read_file/;
 use JavaScript::Minifier::XS qw/minify/;
 
 sub generate{
@@ -15,9 +8,7 @@ sub generate{
        debug $env => "";
        my $js;
        $js .= read_file $_ for <js/*.js>;
-       [200, ['Content-Type' => 'application/javascript', 'Cache-Control' => 'public, max-age=604800', 'X-Forever' => 1], [$js] ]
+       [200, ['Content-Type' => 'application/javascript', 'Cache-Control' => 'public, max-age=604800', 'X-Forever' => 1], [minify $js] ]
 }
 
-sub variants{ [[js => 1, 'application/javascript', undef, undef, undef, undef]] }
-
 1
This page took 0.016033 seconds and 4 git commands to generate.