Changed the writing behavior of codeblock transformer (buffering it first)
An example of a use case:
(markdown/md-to-html-string "```python\ndef f(x):\n return x * 2\n```"
:codeblock-callback (fn
[code language]
(trim (clygments/highlight code language :html))))
Code above would syntax highlight codeblocks without being bothered to convert the Markdown to HTML first then calling libraries like highlight.js with JavaScript
Changed the writing behavior of codeblock transformer (buffering it first)
An example of a use case:
Code above would syntax highlight codeblocks without being bothered to convert the Markdown to HTML first then calling libraries like highlight.js with JavaScript
References: