Rust-built terminal Markdown previewer with watch mode, fuzzy picker, TOC sidebar, LaTeX-to-Unicode, and stdin streaming for AI workflow piping.
Key Takeaways
Install via curl/PowerShell one-liner, npm, or build from source with cargo build --release; self-updates with SHA256 checksum verification via leaf --update.
Watch mode reloads every 250ms with visual flash feedback; works on Linux, macOS, Windows, and Termux (Android).
Stdin streaming (claude "explain Rust lifetimes" | leaf) is a first-class workflow for piping LLM output directly into a live previewer.
Feature set includes fuzzy Markdown picker, classic directory browser, runtime theme picker, search with match highlighting, TOC with active section tracking, and LaTeX block rendering.
Keybindings follow vim conventions (j/k/d/u/g/G) with additional GUI-style shortcuts for editor integration and file browsing.
Hacker News Comment Review
The main competitive question is how leaf differs from glow; no detailed feature comparison has been provided by the author yet.
A security-minded commenter flagged cargo audit returning 3 vulnerabilities in the dependency tree and suggested the simpler pandoc | lynx pipeline as a supply-chain-safe alternative, questioning whether 225+ crates is justified.
Notable Comments
@SupLockDef: flags 3 cargo audit vulnerabilities and argues pandoc "$@" | lynx -stdin covers the use case with near-zero supply chain surface.