Email::Simple::Markdown::Stuffer - use Email::Simple::Markdown with Email::Stuffer
version 0.7.3
use Email::Simple::Markdown::Stuffer; my $stuffer = with_markdown( Email::Stuffer->new, Email::Simple::Markdown->create( markdown_engine => 'Text::Markdown', pre_markdown_filter => sub { s#:-\)#<img src="smiley" alt="yeee!" /># } ), ); $stuffer->from ('me@babyl.ca' ) ->to ('yanick@babyl.ca' ) ->markdown_body(<<'MD' )->send; # Hi there! Cool, uh? :-) MD
Quick and dirty integration of Email::Simple::Markdown and Email::Stuffer.
Loading this module will automatically load both Email::Stuffer and Email::Simple::Markdown. The function with_markdown is also exported.
with_markdown
with_markdown( $stuffer, $email_simple_markdown_object );
Applies a role to $stuffer, which has to be a Email::Stuffer object> augmenting the object with the method markdown_body. This method takes a markdown text and assign the text_body and html_body with the right values. $email_simple_markdown_object is optional. If not given, an Email::Simple::Markdown object with all the defaults will be used.
$stuffer
markdown_body
text_body
html_body
$email_simple_markdown_object
Yanick Champoux <yanick@cpan.org>
This software is copyright (c) 2022, 2017, 2014, 2013, 2012 by Yanick Champoux.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Email::Simple::Markdown, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Email::Simple::Markdown
CPAN shell
perl -MCPAN -e shell install Email::Simple::Markdown
For more information on module installation, please visit the detailed CPAN module installation guide.