Registry / type-stubs / remark-lint-double-link

remark-lint-double-link

JSON →
library0.2.0jsnpmunverified

remark-lint rule to detect duplicate link URLs in Markdown files. Current stable version is 0.2.0, with sparse releases on-demand. Differentiates from other lint rules by focusing solely on duplicate URLs, not link text or other attributes. Provides both CLI and config integration via `.remarkrc`. Ships TypeScript declarations.

npm install remark-lint-double-link
INSTALL
IMPORT
SIG · REMARK-LINT-DOUBLE
R
remark-lint-double-link
type-stubsjavascriptv0.2.0
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 remarkLintDoubleLink from 'remark-lint-double-link'
const remarkLintDoubleLink = require('remark-lint-double-link')
Package is ESM-only since v0.2.0; CommonJS require will fail without bundler support.
remarkLintDoubleLink
import { default as remarkLintDoubleLink } from 'remark-lint-double-link'
Named import of default export; works in TypeScript.
rule
import { rule } from 'remark-lint-double-link'
Exports a `rule` object for programmatic use with unified.

Shows how to use the remark plugin to lint a Markdown file for duplicate links.

import { read } from 'to-vfile'; import { remark } from 'remark'; import remarkLint from 'remark-lint'; import remarkLintDoubleLink from 'remark-lint-double-link'; const file = await remark() .use(remarkLint) .use(remarkLintDoubleLink) .process(await read('example.md')); console.log(file.messages);
remark --version
Debug
Known issues
breakingESM-only since v0.2.0, require() fails.
fix
Use import syntax or upgrade bundler/Node to support ESM.
affects: >=0.2.0
Errors
Common errors & fixes
TypeError: remarkLintDoubleLink is not a function
Using CommonJS require on an ESM-only package.
fix
Replace require with import statement.
import { rule } from 'remark-lint-double-link' // returns undefined
Named import 'rule' might be the default export in older versions.
fix
Use default import: import remarkLintDoubleLink from 'remark-lint-double-link'
Upgrade
Version history
0.2.0latest on npm
Audit
Dependencies
unified-lint-rulerequiredpeer dependency to integrate with remark-lint
remark-lintrequiredrequired to use lint plugins
Agent activity
19 hits · last 30 days
node
14
OpenAI (training)
2
Amazon
1
Resources
remark-lint-double-link — npm install remark-lint-double-link · libregistry