Registry / testing / remark-changelog

remark-changelog

JSON →
library1.2.1jsnpmunverified

Lint or fix a changelog written in Markdown following Keep a Changelog conventions. Version 1.2.1, maintained by vweevers. Integrates with remark and provides both linting and automatic fixing for headings, version links, dates, ordering, and release content. Supports Unreleased sections, semver versions, GitHub compare links, and commit log insertion. Differentiated by its fix mode and strict adherence to Keep a Changelog.

npm install remark-changelog
INSTALL
IMPORT
SIG · REMARK-CHANGELOG
R
remark-changelog
testingjavascriptv1.2.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 changelog from 'remark-changelog'
import { changelog } from 'remark-changelog'
Default export is the plugin function.
require('remark-changelog')
const changelog = require('remark-changelog')
CommonJS require works in Node <10 and CJS projects.
remark().use(changelog)
remark().use(changelog)
remark().use(changelog, options)
Options can be passed but are not required.

Lint a changelog file using remark-changelog plugin with default options.

const remark = require('remark'); const changelog = require('remark-changelog'); const fs = require('fs'); const content = fs.readFileSync('CHANGELOG.md', 'utf8'); remark() .use(changelog, { lint: true }) .process(content, (err, file) => { if (err) throw err; console.log(file.messages); });
Debug
Known issues
breakingVersion 1.x uses remark 12; not compatible with remark 13+.
fix
Use remarkable or update to remark 12.
affects: >=1.0.0 <2.0.0
gotchaRequires Node >=10; does not support ESM natively.
fix
Use CommonJS or transpile; no ESM exports.
affects: >=1.0.0
gotchaFix mode may reorder releases and changelog entries, potentially causing git conflicts.
fix
Review changes before committing; use version control.
affects: >=1.0.0
Errors
Common errors & fixes
Cannot find module 'remark-changelog'
Missing npm install or incorrect import path.
fix
Run 'npm install remark-changelog' and check require/import path.
TypeError: remark is not a function
Using wrong version of remark (v13+ exports differently).
fix
Ensure remark v12 is installed: 'npm install remark@12'.
Upgrade
Version history
1.2.1latest on npm
Audit
Dependencies
remarkrequiredPeer dependency; this is a remark plugin.
Agent activity
4 hits · last 30 days
node
4
Resources
remark-changelog — npm install remark-changelog · libregistry