The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Mojolicious::Plugin::Handlebars - Text::Handlebars plugin

SYNOPSIS

# Mojolicious $self->plugin('handlebars_renderer'); $self->plugin(handlebarse_renderer => { template_options => { helpers => { add => sub { my($context,$arg1,$arg2) = @_; return $arg1 + $arg2 } } } });

# Mojolicious::Lite plugin 'handlebars_renderer'; plugin handlebars_renderer => { template_options => { helpers => { add => sub { my($context,$arg1,$arg2) = @_; return $arg1 + $arg2 } } } };

DESCRIPTION

Mojolicous::Plugin::HandlebarsRenderer is a simple loader for MojoX::Renderer::Handlebars.

METHODS

Mojolicious::Plugin::HandlebarsRenderer inherits all methods from Mojolicious::Plugin and overrides the following ones:

register

$plugin->register

Registers renderer in Mojolicious application.

SEE ALSO

MojoX::Renderer::Handlebars, Mojolicious

AUTHOR

Robert Grimes, <rmzgrimes at gmail.com>

This code is heavily based on the module Mojolicious::Plugin::XslateRenderer by "gray <gray at cpan.org>"