rehype-prism
A rehype plugin that highlights code blocks in HTML using Prism. It is used when generating documentation pages, and the Mapbox docs team no longer maintains it.
Share on XLicense: MIT
Overview
rehype-prism is a rehype plugin that highlights code blocks in HTML with Prism, through the refractor library. It looks at pre and code elements and uses the language class on the code element to pick the language. It can be used with rehype directly or in a unified pipeline that converts Markdown. It is no longer used or maintained by the Mapbox docs team.
Key features
- Highlights pre and code blocks using Prism via refractor
- Language chosen from a language-name class on the code element
- ignoreMissing option skips unknown languages instead of throwing
- alias option registers alternative language names
Best for
Node based documentation builds that need code highlighting in rehype. It is unmaintained since April 2024, and the README suggests lighter ways to highlight in the browser.
- Upstream
- mapbox/rehype-prism
- Fork on GitHub
- Guo-astro/rehype-prism
- Upstream stars
- 173
- Category
- Developer tools and infrastructure
- Language
- JavaScript
- License
- MIT
- Forked
- 2020-11-01
- Sync status
- In syncLast synced 2026-09-29
More in Developer tools and infrastructure
DBX is a lightweight, cross-platform database client for connecting to and managing over 100 database types. It offers desktop, Docker, and CLI access, plus AI assistance and an MCP Server for database workflows.
Forked 2026-09-29Last synced 2026-09-29License: Apache-2.0Developer tools and infrastructureGitHub
Escrcpy is a graphical desktop interface for scrcpy that mirrors and controls Android devices. It helps developers and testers manage connected devices, including wireless and multi-device workflows.
Forked 2026-09-29Last synced 2026-09-29License: Apache-2.0Developer tools and infrastructureGitHub
Lightpanda is a headless browser built from scratch for AI agents and automation. It aims to be lighter and faster than Chromium and works with Playwright and Puppeteer.
Forked 2026-09-28Last synced 2026-09-29License: AGPL-3.0Developer tools and infrastructureGitHub
A self-hosted open-source monitoring platform for servers, apps and infrastructure. It offers uptime monitoring, distributed checks, incident tracking and alerts.
Forked 2026-09-28Last synced 2026-09-29License: MITDeveloper tools and infrastructureGitHub