{"id":26202,"library":"remark-lint-definition-spacing","title":"remark-lint-definition-spacing","description":"remark-lint rule (v4.0.1, ESM-only) from the remark-lint monorepo that warns when consecutive whitespace (more than one space or non-space whitespace) is used in a definition label. Published as part of the remark-lint ecosystem, it ensures definition label whitespace consistency. Unlike general markdown linters, this rule is specific to definition labels and is included in the remark-preset-lint-markdown-style-guide preset.","status":"active","version":"4.0.1","language":"javascript","source_language":"en","source_url":"https://github.com/remarkjs/remark-lint#main","tags":["javascript","definition","lint","remark","remark-lint","remark-lint-rule","rule","spacing","typescript"],"install":[{"cmd":"npm install remark-lint-definition-spacing","lang":"bash","label":"npm"},{"cmd":"yarn add remark-lint-definition-spacing","lang":"bash","label":"yarn"},{"cmd":"pnpm add remark-lint-definition-spacing","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency; required to use the unified processor","package":"unified","optional":false},{"reason":"peer dependency; must be used together with remark-lint","package":"remark-lint","optional":false}],"imports":[{"note":"Default export - named import does not exist","wrong":"import { remarkLintDefinitionSpacing } from 'remark-lint-definition-spacing'","symbol":"remarkLintDefinitionSpacing","correct":"import remarkLintDefinitionSpacing from 'remark-lint-definition-spacing'"}],"quickstart":{"code":"import remarkLint from 'remark-lint'\nimport remarkLintDefinitionSpacing from 'remark-lint-definition-spacing'\nimport remarkParse from 'remark-parse'\nimport remarkStringify from 'remark-stringify'\nimport {read} from 'to-vfile'\nimport {unified} from 'unified'\nimport {reporter} from 'vfile-reporter'\n\nconst file = await read('example.md')\n\nawait unified()\n  .use(remarkParse)\n  .use(remarkLint)\n  .use(remarkLintDefinitionSpacing)\n  .use(remarkStringify)\n  .process(file)\n\nconsole.error(reporter(file))","lang":"typescript","description":"Shows how to use the rule with unified: parse markdown, apply the lint rule, stringify, and report messages."},"warnings":[{"fix":"Switch to ESM imports (import ... from ...). For CommonJS, use dynamic import() or stick to version 3.x.","message":"Package is ESM-only starting from version 4.","severity":"breaking","affected_versions":">=4.0.0"},{"fix":"Update TypeScript to 5.0+ or use a version with supported module resolution.","message":"TypeScript types changed in version 4.0.0: `@import` syntax used; types may require TypeScript 5.0+.","severity":"breaking","affected_versions":">=4.0.0"},{"fix":"","message":"No known deprecations in this package.","severity":"deprecated","affected_versions":""},{"fix":"No fix needed; it's by design.","message":"This rule does not affect GFM footnotes; footnote labels cannot contain whitespace.","severity":"gotcha","affected_versions":"all"}],"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-spacing` and ensure you use ESM import syntax.","cause":"Missing package installation or wrong import path (ESM vs CJS).","error":"Cannot find module 'remark-lint-definition-spacing'"},{"fix":"Use `import remarkLintDefinitionSpacing from 'remark-lint-definition-spacing'`.","cause":"Using named import `{ remarkLintDefinitionSpacing }` instead of default import.","error":"TypeError: remarkLintDefinitionSpacing is not a function"},{"fix":"Update Node.js to >=16 or use `--experimental-modules` flag (older versions), or use dynamic import.","cause":"Node.js version < 16 or not configured for ESM.","error":"Error: It looks like you are using ESM but your Node.js version does not support it."}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}