Created
December 27, 2013 10:14
-
-
Save fgabolde/8144948 to your computer and use it in GitHub Desktop.
Example Floop app with sugar applied.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use strict; | |
use warnings; | |
use 5.010; | |
use Carp; | |
use mop; | |
use Floop::Confectionery; | |
class Plomo extends Floop { | |
method BUILD { | |
$self->install_plugin('DBIC'); | |
$self->install_plugin('Session', 'YAML'); | |
$self->register_view(html => 'Floop::View::TemplateToolkit'); | |
$self->set_default_view('html'); | |
sugarcoat($self); | |
} | |
method das_route ($app: $context) is GET('/jelly_baby') { | |
push @{$context->response->body}, 'hallelujah'; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment