vuepress / core

Vue-Powered Static Site Generator
https://vuepress.vuejs.org
MIT License
2.29k stars 926 forks source link

[Bug report] 生产环境与开发环境的侧边栏点开不同 #1379

Closed MitchellRyrie-evanBuck closed 1 year ago

MitchellRyrie-evanBuck commented 1 year ago

Description

当我在开发环境时 目录结构与地址如下

image image

当我点击文章的时候 是正常显示的 是有侧边栏的 但是当我部署到正式环境之后 点击

image image

左边栏消失 文章居中了

我确认 生产与开发环境是同一套代码 不止这个目录 所有生产环境的目录结构的文章点击都会居中 开发环境则不会 请问是什么原因导致

文件目录如下

image

生产地址 https://toplus.vip/

Reproduction

...

Used Package Manager

yarn

System Info

"@vuepress/client": "2.0.0-beta.62",
    "@vuepress/plugin-active-header-links": "2.0.0-beta.62",
    "@vuepress/plugin-search": "2.0.0-beta.62",
    "markdown-it-disable-url-encode": "^1.0.1",
    "markdown-it-front-matter": "^0.2.3",
    "vue": "^3.3.4",
    "vuepress": "2.0.0-beta.62",
    "vuepress-vite": "2.0.0-beta.62"
Mister-Hope commented 1 year ago

image

image

Your server and sidebar configuration are case sensitive in links (renders 404 page for /web/Javascript/xxx, but your project links and vuepress router are not.

Make sure all your links satisfies the original casing should solve the problem