1.1.0 • Published 4 years ago
frontformatter v1.1.0
Front Formatter
If you work with hugo, 11ty or any other static site generator, you'll likely end up with a lot of Markdown files after a while.
This script helps to migrate, add or remove properties from Markdwon frontmatter.
Usage
Specify a source folder or copy your markdown files into src
. You can define properties to add and remove, then run the transformation function:
const frontformatter = require('frontformatter')
const addProperties = {
add: 'this'
}
const removeProperties = ['remove']
frontformatter('src', addProperties, removeProperties)
Acknowledgments
Thanks to Jon Schlinkert for gray-matter
Licence
Licensed under MIT.