X-Git-Url: http://git.ieval.ro/?a=blobdiff_plain;f=lib%2FGruntmaster%2FPage%2FLearn.pm;h=95c61821e028f26f49a9ddc034aa4f8690b5597f;hb=bb95f538bf263c0294d87cfb90d58c66117b9aab;hp=1ba2e4ed165c7de4f1e9d511c6a1cfdcf9ac69c6;hpb=cd9af27e94244e6454c3db787a8ca6811f44fc16;p=plack-app-gruntmaster.git diff --git a/lib/Gruntmaster/Page/Learn.pm b/lib/Gruntmaster/Page/Learn.pm index 1ba2e4e..95c6182 100644 --- a/lib/Gruntmaster/Page/Learn.pm +++ b/lib/Gruntmaster/Page/Learn.pm @@ -3,27 +3,15 @@ package Gruntmaster::Page::Learn; use 5.014000; use strict; use warnings; -use parent qw/Exporter/; -our @EXPORT_OK = qw/generate/; +use Gruntmaster::Page::Base learn => 'Learn'; +our @ISA = qw/Gruntmaster::Page::Base/; our $VERSION = '0.001'; -use constant TITLE => 'Learn'; - -use HTML::Template::Compiled; -use Gruntmaster::Page::Common qw/header footer/; - -my %templates = ( - en => <<'HTML', +use constant TEMPLATES => { + en => <<'HTML', Install interactive-perl-tutorial from your nearest CPAN mirror. Run cpan App::InteractivePerlTutorial.

You can also get the source from git.ieval.ro HTML -); - -$templates{$_} = header($_, TITLE) . $templates{$_} for keys %templates; -$templates{$_} .= footer $_ for keys %templates; - -sub generate{ - HTML::Template::Compiled->new(scalarref => \$templates{$_[1]})->output; -} +}; 1