34 lines
1.4 KiB
JavaScript
34 lines
1.4 KiB
JavaScript
|
|
/**
|
|||
|
|
* 配置文档:https://vuepress.vuejs.org/zh/config/
|
|||
|
|
*/
|
|||
|
|
const baseContext = '/doc'
|
|||
|
|
module.exports = {
|
|||
|
|
base: baseContext, // url context 举例:当base为/时。应部署在http://domain/下;当base 为/doc时,应部署在http://domain/doc下
|
|||
|
|
title: 'Hello VuePress', // 网站title
|
|||
|
|
description: 'Just playing around', // 网站<meta>的description
|
|||
|
|
header:[
|
|||
|
|
['link', { rel: 'icon', href: baseContext + '/favicon.ico' }]
|
|||
|
|
],
|
|||
|
|
port: '8080', // dev环境下的服务端口
|
|||
|
|
// locales:{}, // 多语言
|
|||
|
|
//shouldPrefetch: () => {}, // 一个函数,用来控制对于哪些文件,是需要生成 <link rel="prefetch"> 资源提示的。请参考https://ssr.vuejs.org/zh/api/#shouldprefetch
|
|||
|
|
cache: true, // cache-loader开关
|
|||
|
|
extraWatchFiles:[], //指定需要额外监听的重构文件
|
|||
|
|
patterns:['**/*.md', '**/*.vue'], //指定需要处理的文件的名称正则
|
|||
|
|
plugins:['@vuepress/medium-zoom', '@vuepress/back-to-top','@vuepress/active-header-links'], // 插件https://vuepress.vuejs.org/zh/plugin/using-a-plugin.html,
|
|||
|
|
themeConfig: {
|
|||
|
|
// 搜索框右侧导航栏
|
|||
|
|
nav: [
|
|||
|
|
{ text: '首页', link: '/' },
|
|||
|
|
],
|
|||
|
|
// 侧边导航栏
|
|||
|
|
sidebar: [
|
|||
|
|
{
|
|||
|
|
title:'首页',
|
|||
|
|
path:'/'
|
|||
|
|
}
|
|||
|
|
],
|
|||
|
|
// 文章h2遍历生成深度
|
|||
|
|
sidebarDepth: 3
|
|||
|
|
}
|
|||
|
|
}
|