Templa...xtile2(3pm)
β¨ Template::Plugin::Textile2 β¨
okay bestie, welcome to Template::Plugin::Textile2 β that's a module from the User Contributed Perl Documentation crew, and she's here to serve. π
πΈ NAME πΈ
Template::Plugin::Textile2 β the way to use Textile formatting with Template Toolkit. no cap. π§
π SYNOPSIS π
watch this slay:
[% USE Textile2 -%]
[% FILTER textile2 %]This *bold* and this is _italic_.[% END %]
<p>this is <strong>bold</strong> and this is <em>italic</em>.
[% USE Textile2 ( disable_html => 1 ) -%]
[% FILTER textile2 %]this is<br /> _italic_.[% END %]
<p>this is<br /> <em>italic</em>.</p>
see how the input just became HTML? that's her. that's the whole vibe. β¨
π DESCRIPTION π
so basically this module wraps Text::Textile into a plugin for Template Toolkit. π«Ά
it hands you a filter named textile2, and she is highkey aiming to be a more feature-full version of Template::Plugin::Textile, because she lets you pass parameters straight through to Text::Textile. main character energy, honestly. π
use her like this:
[% FILTER textile2 %]
Reasons to use the Template Toolkit:
* Seperation of concerns.
* It's written in Perl.
* Badgers are Still Cool.
[% END %]
or like this, if you're feeling compact:
[% mytext | textile2 %]
and here's the good part β you can pass the same options you would pass to Text::Textile, directly when using the template. for instance, if you wanna disable processing of HTML tags, you just do:
[% USE Textile2 ( disable_html => 1 ) %]
and if you want to avoid your text getting wrapped up in <p>...</p>, you can use:
[% USE Textile2 ( format_mode => 'inline' ) %]
that's the trick, iykyk. π€«
fr fr, go see Text::Textile for all the details β she's the one holding the lore. π
π AUTHOR π
Michele Beltrame mb@italpro.net. iconic. β¨
π LICENSE π
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. periodt. π
π¦ SEE ALSO π¦
Text::TextileTemplate
and that's a wrap, bestie π this page came to you from perl v5.34.0, dated 2022-06-17, and she ate. no crumbs. πβ¨
π¦ where this page comes from
- debian bookworm: libtemplate-plugin-textile2-perl 1.21-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libtemplate-plugin-textile2-perl 1.21-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libtemplate-plugin-textile2-perl 1.21-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libtemplate-plugin-textile2-perl 1.21-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libtemplate-plugin-textile2-perl 1.21-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms