qmetrics.net

Comrak

CommonMark and GFM Markdown parser and renderer

Comrak screenshot

Comrak parses and renders CommonMark and GitHub Flavored Markdown in Rust, as a library, CLI, and language bindings. It targets CommonMark 0.31.2 by default.

Overview

Comrak is a Markdown parser and renderer that implements CommonMark and GitHub Flavored Markdown. You can use it from Rust code, from a standalone command-line binary, or through bindings for Ruby, Python, JavaScript, and other languages, including a WebAssembly build for browsers.

By default it follows CommonMark 0.31.2. GFM extensions can be toggled collectively or enabled individually, alongside many Comrak-specific extensions such as alerts, footnotes, math, wikilinks, and Obsidian-oriented features. Parsing can produce HTML directly or build an AST you manipulate before rendering.

Security-minded defaults scrub raw HTML and dangerous links unless you opt into unsafe mode. Optional plugins add syntax highlighting for fenced code blocks, including a Syntect adapter. Custom formatters can override rendering for selected node types without rewriting the whole pipeline.

The CLI is packaged for several Unix package managers and via cargo install. GitLab and other products use Comrak to render Markdown in documents and UI surfaces.

Key features

  • CommonMark 0.31.2 compliance
  • GitHub Flavored Markdown extensions
  • AST parse and custom render path
  • Safe default HTML sanitization
  • Pluggable syntax highlighting
  • Many community Markdown extensions
  • CLI and multi-language bindings
  • WASM use in web pages

Use cases

  • Rendering Markdown in applications
  • Converting Markdown via CLI pipelines
  • Git-hosted README generation
  • GFM-compatible documentation sites

Tags

Similar software

TypeScript

Typed JavaScript language with compile-time checks

TypeScript adds optional static types to JavaScript and compiles to standard JavaScript. It targets application-scale code on browsers, Node.js, and other JavaScript runtimes.

★ 111.9k⟳ yesterdayApache-2.0

Carbon Lang

Experimental successor language interoperating with C++

Carbon Language is an experimental programming language and toolchain aimed at C++ interoperability, migration, and modernization. It is not ready for production use and remains under active development.

★ 34k⟳ yesterdayApache-2.0 · open core

Roslyn

Open-source C# and Visual Basic compiler platform APIs

Roslyn implements the .NET C# and Visual Basic compilers and exposes APIs for analyzing, refactoring, and generating .NET code in tools and applications.

★ 20.8k⟳ todayMIT

GopherJS

Go to JavaScript compiler for browser front-end code

GopherJS translates Go programs into JavaScript so front-end logic can run in browsers. Install the gopherjs CLI to build, test, and serve packages like the standard go tool.

★ 13.2k⟳ 16 days agoBSD-2-Clause

Halide

Embedded language for fast image and array pipelines

Halide helps write high-performance image and array processing code, embedded in C++ or Python. Pipelines compile to CPUs and multiple GPU compute APIs.

★ 6.6k⟳ todayMIT · open core

The Agda Wiki

Dependently typed functional language and interactive proof assistant

Agda combines a dependently typed functional programming language with an interactive environment for writing and checking constructive proofs.

★ 3k⟳ yesterdayMIT