Panache

Panache is a formatter, LSP server, and linter for Pandoc Markdown, Quarto, and R Markdown documents. It is designed to be fast, configurable, and fully support the rich syntax of Pandoc Markdown, including features like fenced divs, grid tables, definition lists, inline footnotes, and more.

Key Features

  • Full Pandoc syntax support: Handles fenced divs, grid tables, definition lists, inline footnotes, and more
  • Math formatting: Intelligent formatting for inline and display math
  • External formatter integration: Hook into language-specific formatters (R, Python, Rust, etc.) for code blocks
  • Ignore directives: Selectively disable formatting and linting for specific regions
  • Built-in linter: Check for heading hierarchy, duplicate references, and citation issues
  • Language Server Protocol: Built-in LSP for editor integration with format-on-save
  • Fast and configurable: Written in Rust with sensible defaults

Quick Start

Installation

Install panache from crates.io:

cargo install panache

Or download and install pre-built binaries from the releases page. Available for:

Basic Usage

Format a document:

panache format document.qmd

Why panache?

Existing formatters like Prettier and mdformat don’t fully support Pandoc’s extended Markdown syntax used in Quarto and R Markdown documents. panache is built specifically to handle:

  • Fenced divs (::: {.class})
  • All table types (grid, pipe, simple, multiline)
  • Inline footnotes (^[text])
  • Citations ([@ref])
  • Raw blocks and attributes
  • And much more

Status

Warning

This project is in early development. Expect bugs, missing features, and breaking changes.

Learn More