A linting tool for validating and formatting tldr pages. Version 0.0.22 (stable) is actively maintained with frequent releases. It checks against 30+ rules (TLDR001–TLDR109) covering formatting, capitalization, punctuation, and structure. Unlike generic markdown linters, it is purpose-built for the tldr page format and includes an auto-format option (-f). Requires Node >=22, supports CLI use, Docker, and programmatic API.
npm install tldr-lintNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows programmatic linting and formatting of a tldr page string using ESM imports.
Use file paths in CLI arguments; use content string when importing.
Upgrade Node to v22 or later.
Use exactly 'More information: ' (with space after colon).
Use exactly 'Note: ' (with space after colon).
Use -o <file> or -i for in-place formatting.
Change to import tldrLint from 'tldr-lint' and ensure your project is ESM (type: module in package.json or .mjs extension).
Use import { lint } from 'tldr-lint' directly, or use default export and destructure: const { lint } = tldrLint.Remove leading whitespace from the file.
Change 'Prints' to 'Print', 'Printing' to 'Print'.