hbl-cmark
v0.1.0
Published
A helper for Handlebars that adds
Downloads
1
Readme
hbl-cmark
A helper for Handlebars that adds CommonMark rendering. Meant to supercede helpers/handlebars-helpers`' CommonMark helpers.
Usage
const Handlebars = require('handlebars');
require('hbl-cmark').default();
const tpl = Handlebars.compile('{{#markdown}}I sure **do** love Markdown.{{/markdown}}');
console.log(tpl()); // result : '<p>I sure <b>do</b> love Markdown.</p>\n'
Package documentation
{{# markdown}}
Render Markdown that's within the block.
Usage :
{{#markdown}}
I sure **do love Markdown.**
{{/markdown}}
Result : <p>I sure <b>do</b> love Markdown.</p>\n
{{ md str }}
Usage : {{ md "test.md" }}
Result : <p><em>Neutralis</em></p>\n
Acknowledgements
This package is licensed under the 3-Clause BSD licence. A copy of it can be found in the LICENSE
file in the root of the source repository and in the root of the package directory.