npm.io
0.1.0 • Published 8 years ago

pandoc-filter-promisified

Licence
MIT
Version
0.1.0
Deps
1
Size
52 kB
Vulns
0
Weekly
0
DeprecatedThis package is deprecated

About

Node.js port of the Python pandocfilters for filtering with Pandoc

Install

npm install -g pandoc-filter-promisified

Example

#!/usr/bin/env node

// Pandoc filter to convert all text to uppercase

var pandoc = require('pandoc-filter-promisified');
var Str = pandoc.Str;

async function action(elt,format,meta) {
	if (elt.t === 'Str') return Str(elt.c.toUpperCase());
}

pandoc.stdio(action);

Compatibility Note

v0.1.6 is required for pandoc versions after 1.17.2 to support the new JSON format. See this issue for details.

Credits

Thanks to John MacFarlane for Pandoc.

Thanks to Mike Henderson for the original version of pandoc-filter for Node.

License

MIT

Keywords