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

Dancer::Template::Mason - Mason wrapper for Dancer

VERSION

version 0.000_002

SYNOPSIS

 set template => 'mason';
 
 get '/foo', sub {
        template 'foo.mason' => {
        title => 'bar'
        };
 };

Then, on views/foo.mason:

    <%args>
    $title
    </%args>

    <h1><% $title %></h1>

    <p>Mason says hi!</p>

DESCRIPTION

This class is an interface between Dancer's template engine abstraction layer and the HTML::Mason templating system.

In order to use this engine, set the following setting as the following:

    template: mason

This can be done in your config.yml file or directly in your app code with the set keyword.

SEE ALSO

Dancer, HTML::Mason