Skip to content

v0.12.0

Compare
Choose a tag to compare
@github-actions github-actions released this 03 Dec 07:20
· 105 commits to master since this release

   🚀 Features

Migrate to Shikiji  -  by @atomiks and Dimitri POSTOLOV in #109 (b6823)

npm i rehype-pretty-code@latest shikiji@0.7.x && npm uninstall shiki
  • More semantic generated HTML.
  • [data-rehype-pretty-code-fragment] is now a <figure> element ([data-rehype-pretty-code-figure]), and the title or caption is inside a <figcaption> element.
  • Highlighted chars are now wrapped in <mark>.
  • Client-side usage works out of the box, with smaller size.
  • Multiple themes now renders a single block and uses CSS variables to change colors. data-theme has a space-separated list of the actual theme names, instead of the color mode.
  • Inline code highlighting can now be escaped.
    View changes on GitHub