4.0.0 • Published 4 months ago

metalsmith-moment v4.0.0

Weekly downloads
12
License
MIT
Repository
github
Last release
4 months ago

metalsmith-moment

A Metalsmith plugin to convert a set of file metadata to moment.js objects.

Build status

Installation

This plugin requires Node.js 18 or later

$ npm install metalsmith-moment

JavaScript usage

const msMoment = require("metalsmith-moment");

metalsmith.use(msMoment(["published", "modified"]));

This will convert the published and modified properties to moment.js objects by applying moment.js parsing rules. Any falsy property is just ignored.

CLI usage

{
  "plugins": {
    "metalsmith-moment": ["published", "modified"]
  }
}

License

MIT

4.0.0

4 months ago

3.0.0

2 years ago

2.2.0

2 years ago

2.1.0

4 years ago

2.0.0

4 years ago

1.1.0

6 years ago

1.0.0

8 years ago