A remark-lint rule that warns when markdown definitions (including footnote definitions) are not sorted alphabetically. Version 1.0.1 is current, released as part of the remark-lint monorepo. It requires remark-lint and unified, and is ESM-only since Node 16+. Unlike general linters, it enforces a consistent order for 'definition' nodes (e.g., [label]: url), helping maintain readability in long lists. Definitions and footnotes are sorted separately, and 'groups' separated by non-definition content are sorted independently.
npm install remark-lint-definition-sortNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Demonstrates how to programmatically lint markdown definitions sorting using unified pipeline with remark-lint.
Switch to ESM (import) or downgrade to a hypothetical CJS version (none exists).
No action needed; monitor remark-lint releases for combined definitions linting.
Ensure footnotes are in a separate block from regular definitions.
If you need strict global sorting, avoid separating definitions with paragraphs.
Use import syntax or set "type": "module" in package.json.
Change to 'import remarkLintDefinitionSort from 'remark-lint-definition-sort'' (default import).