Registry / testing / remark-lint-ordered-list-marker-value

remark-lint-ordered-list-marker-value

JSON →
library4.0.1jsnpmunverified

A remark-lint rule to check the marker value of ordered lists in Markdown. Current version 4.0.1, part of the remark-lint ecosystem, released as needed. It enforces one of three styles: 'one' (all markers must be 1), 'ordered' (sequential increment), or 'single' (same as first). The default 'consistent' infers style from the first two-item list. Works with unified, ESM-only. Commonly used in lint presets like remark-preset-lint-consistent.

npm install remark-lint-ordered-list-marker-value
INSTALL
IMPORT
SIG · REMARK-LINT-ORDERE
R
remark-lint-ordered-list-marker-value
testingjavascriptv4.0.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

default
✓ import remarkLintOrderedListMarkerValue from 'remark-lint-ordered-list-marker-value'
✗ const remarkLintOrderedListMarkerValue = require('remark-lint-ordered-list-marker-value')
Default export; ESM-only since v4, no CommonJS support.
Options
✓ import type { Options } from 'remark-lint-ordered-list-marker-value'
✗ import { Options } from 'remark-lint-ordered-list-marker-value'
TypeScript type export, not a runtime value.
Style
✓ import type { Style } from 'remark-lint-ordered-list-marker-value'
TypeScript type export; used for options configuration.

Demonstrates using remark-lint-ordered-list-marker-value with unified, parsing Markdown, linting with 'ordered' style, and outputting the result.

import { unified } from 'unified' import remarkParse from 'remark-parse' import remarkStringify from 'remark-stringify' import remarkLint from 'remark-lint' import remarkLintOrderedListMarkerValue from 'remark-lint-ordered-list-marker-value' const processor = unified() .use(remarkParse) .use(remarkStringify) .use(remarkLint) .use(remarkLintOrderedListMarkerValue, 'ordered') const md = '1. Item 1\n2. Item 2\n' const result = await processor.process(md) console.log(String(result))
Debug
Known issues
breakingESM-only: Package does not support CommonJS require() in v4+.
fix
Switch to ESM imports (import statement) or downgrade to v3 if CJS is required.
affects: >=4.0.0
gotchaOptions: The 'consistent' option infers style from the first list with two or more items; lists with single items are ignored.
fix
Explicitly set style to 'one', 'ordered', or 'single' to avoid unexpected inference.
affects: all
deprecatedNode version: Requires Node.js 16+; older versions may not work.
fix
Upgrade Node.js to 16 or later.
affects: >=4.0.0
gotchaNo CJS support: This package is ESM-only; bundlers must handle ESM.
fix
Ensure your environment or bundler supports ESM.
affects: >=4.0.0
Errors
Common errors & fixes
Error [ERR_REQUIRE_ESM]: require() of ES Module /path/to/node_modules/remark-lint-ordered-list-marker-value/index.js from /path/to/file.js not supported.
Using CommonJS require() on an ESM-only package.
fix
Replace require() with import statement or use dynamic import().
TypeError: remarkLintOrderedListMarkerValue is not a function
Misconfigured options or forgetting to call .use() properly.
fix
Ensure you pass the plugin function directly to unified().use(), e.g., .use(remarkLintOrderedListMarkerValue, 'ordered').
Cannot find module 'remark-lint-ordered-list-marker-value'
Package not installed or resolution failed.
fix
Run npm install remark-lint-ordered-list-marker-value and ensure node_modules is accessible.
Upgrade
Version history
4.0.1latest on npm
Audit
Dependencies
remark-lintoptionalrequires remark-lint to function as a linting plugin
unifiedoptionalworks as a unified plugin
Agent activity
2 hits · last 30 days
node
2
Resources
remark-lint-ordered-list-marker-value — npm install remark-lint-ordered-list-marker-value · libregistry