vuepress-automenu
v1.5.3
Published
A package used for generating a sidemenu based on the file structure
Downloads
37
Maintainers
Readme
Vuepress auto-menu
A package which gives you the option to automatically generate the side and nav menu structure based on your filestructure. The sidebar will be based on folder names and file names and the nav menu will only use folder names.
Installation:
NPM:
npm i vuepress-automenu
Yarn:
yarn i vuepress-automenu
Usage:
You use the getSidebarItems()
or getNavbarItems()
functions, depending on which one you need to get all the menu items. It uses {projectfolder}/docs
as default location but you can change it by adding your folder as parameter to either of the functions. (like this: src
)
import { getSidebarItems, getNavbarItems } from 'vuepress-automenu';
export default defineUserConfig({
theme: defaultTheme({
navbar: getNavbarItems(),
sidebar: getSidebarItems()
}),
})
Collaboration:
If you want to report bugs, propose features or view what I'm working on you can use the Github link below.
https://github.com/Alphaegen/vuepress-automenu