Transform from confluence flavored HTML to Markdown with enhanced features.
# npm
npm i -g cf2md
# pnpm
pnpm i -g cf2md
# yarn
yarn global add cf2md
Usage: cf2md [options] [input]
Arguments:
input Input HTML codes
Options:
-V, --version output the version number
-i, --input <path> Input HTML file
-o, --output <path> Output Markdown file
-h, --help display help for command
import fs from 'fs'
import { cf2md } from 'cf2md'
// string
const markdown = cf2md(html)
// stream
cf2md(fs.createReadStream(htmlFile)).pipe(fs.createWriteStream(mdFile))
Detailed changes for each release are documented in CHANGELOG.md.