saberland/saber
The issue has been solved
Inject markdown headers as page attributes #51
egoist posted onGitHub
Add a markdown-it plugin to inject markdown headers [{ text: 'Hello', slug: hello' }]
as page.attributes.markdownHeaders
, similar to Vuepress's this.$page.headers
.
When to inject:
page.attributes.injectMarkdownHeaders === true
- Or
page.attributes.injectMarkdownHeaders !== false && api.config.markdown.injectMarkdownHeaders
The injected markdown headers can be used by https://github.com/egoist/saber/pull/49