Catalyst::Helper::View::Xslate - Helper for Xslate Views
For a standard (Kolon) syntax
script/create.pl view HTML Xslate
Alternatively, for a Template-Toolkit syntax:
script/create.pl view HTML Xslate bridge=TT2 syntax=TTerse
This is a helper module for Xslate Views. It is not meant to be used directly. Instead, you should use your Catalyst app's "create" script (see the SYNOPSIS for syntax).
As any other view helper, the first argument is your View's name. In the synopsys example we used "HTML", and it's usually a good name :)
The Xslate helper accepts the same construction arguments as Text::Xslate itself. List arguments can be separated by comma:
script/create.pl view HTML Xslate cache=2 header=foo.tx,bar.tx suffix=.tt
For convenience, it also takes the following argument:
bridge - The optional bridge method. It can be set to TT2 for Template-Toolkit compatibility, or TT2Like for a similar layer, but that doesn't require Template-Toolkit installed at all.
bridge
TT2
TT2Like
So, if you specify bridge=TT2Like (for example), you'll automatically get:
bridge=TT2Like
module => [ 'Text::Xslate::Bridge::TT2Like' ]
If you also wish to use TT's syntax, remember to also pass syntax=TTerse on the command line.
syntax=TTerse
This method is used by the Catalyst helper engine to generate files properly.
Catalyst::View::Xslate, Catalyst::Manual, Catalyst::Helper, Text::Xslate.
Breno G. de Oliveira <garu@cpan.org>
<garu@cpan.org>
This library is free software . You can redistribute it and/or modify it under the same terms as perl itself.
To install Catalyst::View::Xslate, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Catalyst::View::Xslate
CPAN shell
perl -MCPAN -e shell install Catalyst::View::Xslate
For more information on module installation, please visit the detailed CPAN module installation guide.