Syntax highlighter

Paste code and convert to highlighted HTML locally in your browser. Each language is its own small component — TypeScript’s is 9.34 kB of WebAssembly — chained with an HTML escaper and a Night Owl stylesheet.

Preview
Output HTML

The output embeds its own <style>, so it pastes straight into a blog post or email with no external stylesheet.

Download #

CLI equivalent #

The highlighters transform whole HTML documents: each rewrites <pre><code class="language-…"> blocks for its language and leaves everything else untouched, so they chain safely.

qip run components/text/html/html-code-syntax-highlight-zig.wasm \
  components/text/html/html-code-syntax-highlight-css.wasm \
  components/text/html/html-code-syntax-highlight-bash.wasm \
  components/text/html/html-add-highlight-stylesheet-night-owl.wasm \
  < page.html > highlighted.html