vuepress config.js 简单配置

799 阅读1分钟
// import sidebarArr from './config/sidebar'
module.exports = {
  title: 'note',
  description: 'Just a note about js',
  themeConfig:{
    nav: [
      { text: '首页', link: '/' }, 
      { text: 'External', link: 'https://baidu.com', target:'_self', rel:'' },
      { text: 'h5', link: '/h5/js-bridge'},
      { text: 'js-base', link: '/js_base/array'},
      {
        text: '下拉测试', 
        items:[
          { text: '分组a', link: '/js_base/array' },
          { text: '分组b', link: '/js_base/function' },
        ]
      }
    ],
    sidebar: {
      '/js_base/':[{
        title: 'js基础',
        collapsable: false, // 是否能收起来
        children: [
          { title: '基础a', path:'/js_base/array'},
          { title: '函数部分', path:'/js_base/function'}
				]
      }],
      '/h5/':[{
        title: 'h5原生',
        collapsable: false,
        children: [
			{ title: 'js-bridge', path:'/h5/js-bridge'},
			{ title: '适配', path:'/h5/适配'}
				]
      }],
    }
    // navbar: false,
    // sidebarDepth: 1,  //侧边菜单深度
  },
  



  plugins: ['@vuepress/back-to-top'],
  port: 8888

}