{"id":26201,"library":"remark-lint-definition-case","title":"remark-lint-definition-case","description":"A remark-lint rule that warns when definition labels in Markdown are not lowercase, helping enforce consistent casing. Current stable version is 4.0.1, published as part of the remark-lint monorepo. The plugin is ESM-only, supports Node.js 16+, and is compatible with remark-lint presets like remark-preset-lint-markdown-style-guide. It works with regular definitions and GFM footnote definitions. No options are required.","status":"active","version":"4.0.1","language":"javascript","source_language":"en","source_url":"https://github.com/remarkjs/remark-lint#main","tags":["javascript","case","definition","lint","remark","remark-lint","remark-lint-rule","rule","typescript"],"install":[{"cmd":"npm install remark-lint-definition-case","lang":"bash","label":"npm"},{"cmd":"yarn add remark-lint-definition-case","lang":"bash","label":"yarn"},{"cmd":"pnpm add remark-lint-definition-case","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Required for integration with the unified processing pipeline","package":"unified","optional":false},{"reason":"Provides the linting infrastructure and message formatting","package":"remark-lint","optional":false}],"imports":[{"note":"ESM-only since v4; CJS require will throw an error.","wrong":"const remarkLintDefinitionCase = require('remark-lint-definition-case')","symbol":"remarkLintDefinitionCase","correct":"import remarkLintDefinitionCase from 'remark-lint-definition-case'"},{"note":"The package has a default export, not a named export.","wrong":"import { remarkLintDefinitionCase } from 'remark-lint-definition-case'","symbol":"default export","correct":"import remarkLintDefinitionCase from 'remark-lint-definition-case'"},{"note":"The rule is a plugin function, not a factory; do not call it.","wrong":".use(remarkLintDefinitionCase())","symbol":"unified .use()","correct":".use(remarkLintDefinitionCase)"}],"quickstart":{"code":"import { read } from 'to-vfile'\nimport { reporter } from 'vfile-reporter'\nimport { unified } from 'unified'\nimport remarkParse from 'remark-parse'\nimport remarkStringify from 'remark-stringify'\nimport remarkLint from 'remark-lint'\nimport remarkLintDefinitionCase from 'remark-lint-definition-case'\n\nconst file = await read('example.md')\n\nawait unified()\n  .use(remarkParse)\n  .use(remarkLint)\n  .use(remarkLintDefinitionCase)\n  .use(remarkStringify)\n  .process(file)\n\nconsole.error(reporter(file))","lang":"typescript","description":"Shows how to use remark-lint-definition-case in a unified pipeline to lint a Markdown file and output messages."},"warnings":[{"fix":"Use import syntax instead of require(). Ensure Node.js version 16+.","message":"v4.0.0: Package became ESM-only; removed CommonJS support.","severity":"breaking","affected_versions":">=4.0.0"},{"fix":"No action needed; this is by design. Ensure definition labels are lowercase to avoid warnings.","message":"The rule checks definition labels (e.g., [label]: url) but does not affect reference labels (e.g., [label]) which are matched case-insensitively.","severity":"gotcha","affected_versions":">=1.0.0"},{"fix":"Do not pass options to the plugin.","message":"The rule does not accept any options; passing options will be ignored silently.","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run 'npm install remark-lint-definition-case' and ensure import path is correct.","cause":"Missing npm install or incorrect import path.","error":"Cannot find module 'remark-lint-definition-case'"},{"fix":"Use the import directly: .use(remarkLintDefinitionCase), not .use(remarkLintDefinitionCase()).","cause":"Attempting to call the imported default export as a factory (e.g., remarkLintDefinitionCase()).","error":"remarkLintDefinitionCase is not a function"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}