The tiny syntax highlighting library for dynamic input.
Its core library has only 0.5 KB JavaScript!
npm install picolightimport { highlight } from "picolight";
import { scheme } from "picolight/languages/scheme";
import { githubDark } from "picolight/themes/github-dark";
const code = document.querySelector("code");
code.innerHTML = highlight(
`(write-string "Hello, world!\\n")`,
scheme,
githubDark,
).outerHTML;- Scheme
- TypeScript
- Other languages might be coming, maybe...
We support all TextMate themes provided by Shiki.