https://github.com/metalsmith/headings
A Metalsmith plugin that extracts headings from HTML files and attaches them to the file's metadata.
https://github.com/metalsmith/headings
headings html metalsmith metalsmith-plugin
Last synced: 2 months ago
JSON representation
A Metalsmith plugin that extracts headings from HTML files and attaches them to the file's metadata.
- Host: GitHub
- URL: https://github.com/metalsmith/headings
- Owner: metalsmith
- Created: 2014-04-02T18:48:24.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2017-10-06T15:43:09.000Z (about 8 years ago)
- Last Synced: 2025-07-02T19:58:11.562Z (3 months ago)
- Topics: headings, html, metalsmith, metalsmith-plugin
- Language: JavaScript
- Homepage:
- Size: 4.88 KB
- Stars: 22
- Watchers: 38
- Forks: 8
- Open Issues: 4
-
Metadata Files:
- Readme: Readme.md
- Changelog: History.md
Awesome Lists containing this project
README
# metalsmith-headings
A Metalsmith plugin that extracts headings from HTML files and attaches them to the file's metadata.
## Installation
$ npm install metalsmith-headings
## Example
```js
var Metalsmith = require('metalsmith');
var headings = require('metalsmith-headings');Metalsmith(__dirname)
.use(headings('h2'))
.build();
```## License
MIT