vuepress-plugin-child-toc
Display child page table of content on your vuepress documentation
Requirements
- This plugin requires VuePress >= 1.0.0.
Features
Add a <ChildTableOfContents />
component that you can use in your markdown in order to get a Table of Contents for all the child page (meaning url starting with the current page url).
Install
npm i vuepress-plugin-child-toc
Usage
Using this plugin:
// .vuepress/config.jsmoduleexports = plugins: 'vuepress-plugin-child-toc'
then add your table of components where you want in your markdown pages:
# All child page table of contents<ChildTableOfContents /> # All child page table of contents with max 2 max distance level<ChildTableOfContents :max="2"/> # Add internal, anchor link in the table of contents<ChildTableOfContents :header="true"/> # Display Child TOC for this specific page<ChildTableOfContents pageUrl="/blogs/"/>
Inspiration
Largely inspired from plugin vuepress-plugin-global-toc