Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^2: Dancer2 Module for Generating HTML from markdown

by nysus (Vicar)
on Nov 05, 2018 at 21:28 UTC ( #1225293=note: print w/replies, xml ) Need Help??


in reply to Re: Dancer2 Module for Generating HTML from markdown
in thread Dancer2 Module for Generating HTML from markdown

OK, I dug harder into the Text::Markdown::Hoedown module which uses XS to load some C module that converts markdown to HTML. I was able to figure out how to get it to work with with "fenced" code (code surrounded by a pair to triplet backticks), which is what the GitHub markdown dialect recognizes. I'll release the next version of the module without Markdent, no Moose required.

Now I can get complaints from people who only like pure perl modules. :)

$PM = "Perl Monk's";
$MCF = "Most Clueless Friar Abbot Bishop Pontiff Deacon Curate Priest Vicar";
$nysus = $PM . ' ' . $MCF;
Click here if you love Perl Monks

Replies are listed 'Best First'.
Re^3: Dancer2 Module for Generating HTML from markdown
by nysus (Vicar) on Nov 05, 2018 at 21:38 UTC

    For those interested, back of the envelope calculations in my head say the Hoedown module converts about 5 times faster than Markdent based on my page load times on uncached content.

    $PM = "Perl Monk's";
    $MCF = "Most Clueless Friar Abbot Bishop Pontiff Deacon Curate Priest Vicar";
    $nysus = $PM . ' ' . $MCF;
    Click here if you love Perl Monks

Re^3: Dancer2 Module for Generating HTML from markdown
by stevieb (Canon) on Nov 06, 2018 at 18:09 UTC
    "Now I can get complaints from people who only like pure perl modules."

    Nah, just from those who don't like having to install Dist::Zilla and a thousand plugins for installation ;)

    ps. I'm not knocking Dist::Zilla, I just personally find that it adds a ton of bloat to more-often-than-not a very small distribution.

      Hi Steve, I think you are suffering from (and spreading) the common misunderstanding that Dist::Zilla is distributed with the distributions it is used to build. Dist::Zilla is simply a distribution-building and -packaging tool, designed for CPAN, and the distributions it builds are simply conformant CPAN distros. No bloat whatsoever, unless you count a dist.ini file that's sometimes left in the distro.

      Here's the entire MANIFEST from Dancer2::Logger::LogAny, which is packaged and distributed with Dist::Zilla:

      # This file was automatically generated by Dist::Zilla::Plugin::Manife +st v6.010. Changes LICENSE MANIFEST META.json META.yml Makefile.PL README.md cpanfile example/README example/app.pl example/config.yml lib/Dancer2/Logger/LogAny.pm t/00-load.t t/config.yml t/logger.t xt/pod-coverage.t
      Installers of this module have no need of Dist::Zilla or its dependencies. (And note that the source repo only has two extra files, a couple of .ini config files.

      (What you may be recalling is the pain a developer can feel when wanting to contribute to a distribution that is packaged with Dist::Zilla, when you have to have it installed to see that your changes lead to a correct build.)

      Hope this helps!



      The way forward always starts with a minimal test.

      You can only pry Dist::Zilla from my cold, dead hands.

      $PM = "Perl Monk's";
      $MCF = "Most Clueless Friar Abbot Bishop Pontiff Deacon Curate Priest Vicar";
      $nysus = $PM . ' ' . $MCF;
      Click here if you love Perl Monks

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1225293]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (8)
As of 2020-06-01 06:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?