\r\n2. 配置文件如下所示:\u003Cbr /> \n\n### Expected behavior\n\n使用 Github 自带的 https://xihuanxiaorang.github.io/docs/ 访问就没有任何问题,如果是使用自定义域名 https://docs.xiaorang.fun/ 的话,样式就会丢失\n\n### System Info\n\n```Text\nSystem:\r\n OS: Windows 10 10.0.19045\r\n CPU: (4) x64 Intel(R) Core(TM) i5-5200U CPU @ 2.20GHz\r\n Memory: 659.73 MB / 3.92 GB\r\n Binaries:\r\n Node: 20.11.0 - E:\\nodejs\\node.EXE\r\n Yarn: 1.22.21 - E:\\nodejs\\node_global\\yarn.CMD\r\n npm: 10.2.4 - E:\\nodejs\\npm.CMD\r\n pnpm: 8.14.3 - E:\\nodejs\\node_global\\pnpm.CMD\r\n Browsers:\r\n Edge: Chromium (120.0.2210.144)\r\n Internet Explorer: 11.0.19041.3636\r\n npmPackages:\r\n vitepress: 1.0.0-rc.40 => 1.0.0-rc.40\n```\n\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Check if you're on the [latest VitePress version](https://github.com/vuejs/vitepress/releases/latest).\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [X] Read the [docs](https://vitepress.dev).\n- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[2928],{"name":2929,"color":2930},"question","5D5FAE",3513,"部署到Github Pages之后,如果使用自定义域名的话样式会丢失","2024-02-07T00:04:15Z","https://github.com/vuejs/vitepress/issues/3513",0.6999084,{"description":2937,"labels":2938,"number":2940,"owner":2869,"repository":2870,"state":2908,"title":2941,"updated_at":2942,"url":2943,"score":2944},"### Describe the bug\n\nThe browser console prints Hydration completed but contains mismatches when deploying the site using Github pages. And the page switch does not work as expected.\r\n\r\n\u003Cimg width=\"404\" alt=\"image\" src=\"https://user-images.githubusercontent.com/25716486/183507530-a390b50c-49e1-4349-a5ba-e1add6883280.png\">\r\n\u003Cimg width=\"1015\" alt=\"image\" src=\"https://user-images.githubusercontent.com/25716486/183507583-86f736b4-7954-40e1-a5aa-a89298d68c72.png\">\r\n\n\n### Reproduction\n\nHere is a reproduced repo: https://github.com/Corona-Studio/CSKB_Hosting\n\n### Expected behavior\n\nThe page switch buttons should work after a click.\n\n### System Info\n\n```shell\nSystem:\r\n OS: Windows 10 10.0.22000\r\n CPU: (16) x64 11th Gen Intel(R) Core(TM) i7-11800H @ 2.30GHz\r\n Memory: 13.26 GB / 31.82 GB\r\n Binaries:\r\n Node: 18.4.0 - C:\\Program Files\\nodejs\\node.EXE\r\n Yarn: 1.22.19 - ~\\node_modules\\.bin\\yarn.CMD\r\n npm: 8.13.1 - C:\\Program Files\\nodejs\\npm.CMD\r\n Browsers:\r\n Edge: Spartan (44.22000.120.0), Chromium (104.0.1293.47)\r\n Internet Explorer: 11.0.22000.120\r\n npmPackages:\r\n vitepress: ^1.0.0-alpha.4 => 1.0.0-alpha.4\n```\n\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [X] Read the [docs](https://vitepress.vuejs.org).\n- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[2939],{"name":2895,"color":2896},1143,"Hydration completed but contains mismatches when using Github pages","2023-01-21T14:28:46Z","https://github.com/vuejs/vitepress/issues/1143",0.7148307,{"description":2946,"labels":2947,"number":2949,"owner":2869,"repository":2870,"state":2908,"title":2950,"updated_at":2951,"url":2952,"score":2953},"### Describe the bug\r\n\r\nFor example the page https://blog.jaggerwang.net/basicai-annotation-specification/ cannot access directly, but it's ok when add `index.html` suffix, and other pages did not have this problem, such as https://blog.jaggerwang.net/basicai-technical-architecture/ . So it seems related to the content of page?\r\n\r\n\u003Cimg width=\"1512\" alt=\"image\" src=\"https://github.com/vuejs/vitepress/assets/1255011/3a69f282-d002-4194-b7ca-3b3075616883\">\r\n\r\nIt's ok when running in local dev and preview mode, and there is no error showing in the browser console or terminal console.\r\n\r\n\u003Cimg width=\"1512\" alt=\"image\" src=\"https://github.com/vuejs/vitepress/assets/1255011/82b87b50-f21a-430e-bb4e-893eb3bf9c52\">\r\n\r\n### Reproduction\r\n\r\nProject structure:\r\n\r\n\u003Cimg width=\"1624\" alt=\"image\" src=\"https://github.com/vuejs/vitepress/assets/1255011/d3f2d9e0-5dc8-4344-9674-61433c5a8322\">\r\n\r\nAliyun OSS config:\r\n\r\n\u003Cimg width=\"1306\" alt=\"image\" src=\"https://github.com/vuejs/vitepress/assets/1255011/d30acd18-d20c-44f2-a872-61bd981d0bcb\">\r\n\r\nBuid with GitHub actions, but the html is same with local build.\r\n\r\n\u003Cimg width=\"1624\" alt=\"image\" src=\"https://github.com/vuejs/vitepress/assets/1255011/f57bef3c-2d76-47c4-b18a-4b4a7b696771\">\r\n\r\n### Expected behavior\r\n\r\nNo error.\r\n\r\n### System Info\r\n\r\n```Text\r\nAliyun OSS\r\n```\r\n\r\n### Additional context\r\n\r\n_No response_\r\n\r\n### Validations\r\n\r\n- [X] Check if you're on the [latest VitePress version](https://github.com/vuejs/vitepress/releases/latest).\r\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\r\n- [X] Read the [docs](https://vitepress.dev).\r\n- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[2948],{"name":2895,"color":2896},3322,"Refresh some pages with error \"Hydration completed but contains mismatches.\" when deployed on Aliyun OSS.","2023-12-21T00:04:35Z","https://github.com/vuejs/vitepress/issues/3322",0.72105473,{"description":2955,"labels":2956,"number":2957,"owner":2869,"repository":2870,"state":2908,"title":2958,"updated_at":2959,"url":2960,"score":2961},"### Describe the bug\r\n\r\n我使用了一个 npm依赖包 `@antd-templater/library-3.x`, 运行 pnpm docs:dev 正常,但是当我运行 pnpm docs:build 时则报如下错误:\r\n\r\n\u003Cimg width=\"1903\" alt=\"image\" src=\"https://github.com/vuejs/vitepress/assets/28494613/6ae2c9d2-e07b-4447-8d08-e5331662d01e\">\r\n\r\n\u003Cbr/>\r\n\r\n@antd-templater/library-3.x 报错代码的文件部分代码\r\n```typescript\r\nimport { defineComponent, ref, onMounted, createVNode, mergeProps } from 'vue';\r\nimport ATooltip from 'ant-design-vue/es/tooltip';\r\nimport * as VueTypes from 'vue-types';\r\n\r\nconst SEllipsis = /* @__PURE__ */ defineComponent({\r\n // ....\r\n})\r\n```\r\n\r\n\r\n### Reproduction\r\n\r\nhttps://stackblitz.com/edit/vite-kzz2up?file=docs%2F.vitepress%2Ftheme%2Findex.ts\r\n\r\n### Expected behavior\r\n\r\n希望可以正常构建\r\n\r\n### System Info\r\n\r\n```Text\r\nSystem:\r\n OS: Linux 5.0 undefined\r\n CPU: (8) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz\r\n Memory: 0 Bytes / 0 Bytes\r\n Shell: 1.0 - /bin/jsh\r\n Binaries:\r\n Node: 18.18.0 - /usr/local/bin/node\r\n Yarn: 1.22.19 - /usr/local/bin/yarn\r\n npm: 10.2.3 - /usr/local/bin/npm\r\n pnpm: 8.15.6 - /usr/local/bin/pnpm\r\n npmPackages:\r\n vitepress: latest => 1.1.4\r\n```\r\n\r\n\r\n### Additional context\r\n\r\n_No response_\r\n\r\n### Validations\r\n\r\n- [X] Check if you're on the [latest VitePress version](https://github.com/vuejs/vitepress/releases/latest).\r\n- [X] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\r\n- [X] Read the [docs](https://vitepress.dev).\r\n- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[],3872,"Error: [ERR_UNSUPPORTED_DIR_IMPORT]: Directory import ...","2024-05-16T04:42:04Z","https://github.com/vuejs/vitepress/issues/3872",0.72730064,{"description":2963,"labels":2964,"number":2966,"owner":2869,"repository":2870,"state":2908,"title":2967,"updated_at":2968,"url":2969,"score":2970},"### Describe the bug\n\nOn https://vitepress.dev/guide/mpa-mode, the documentation says:\n\n> all pages are rendered without any JavaScript included by default\n\nBut that's not the case, this block of code is unconditionally included\n\n```html\n\u003Cscript id=\"check-mac-os\">document.documentElement.classList.toggle(\"mac\",/Mac|iPhone|iPod|iPad/i.test(navigator.platform));\u003C/script>\n```\n\nI don't think there is a way to disable this functionality, outside of doing cursed stuff like\n\n```javascript\nconst head = []\nhead.push = () => {}\n\ndefineConfig({\n ...,\n head,\n})\n```\n\nWhich I imagine isn't exactly supported.\n\n### Reproduction\n\nCreate a website with `mpa: true` and \"Custom Theme\" theme.\n\n### Expected behavior\n\nThere shouldn't be any JavaScript.\n\n### System Info\n\n```Text\nSystem:\n OS: Linux 6.12 cpe:/o:nixos:nixos:25.11 25.11 (Xantusia)\n CPU: (12) x64 AMD Ryzen 5 7640U w/ Radeon 760M Graphics\n Memory: 4.19 GB / 30.66 GB\n Container: Yes\n Shell: 5.2.37 - /nix/store/1q9lw4r2mbap8rsr8cja46nap6wvrw2p-bash-interactive-5.2p37/bin/bash\n Binaries:\n Node: 22.14.0 - /nix/store/c8jxsih8yy2rnncdmx2hyraizf689nvp-nodejs-22.14.0/bin/node\n npm: 10.9.2 - /nix/store/c8jxsih8yy2rnncdmx2hyraizf689nvp-nodejs-22.14.0/bin/npm\n npmPackages:\n vitepress: ^1.6.3 => 1.6.3\n```\n\n### Additional context\n\n_No response_\n\n### Validations\n\n- [x] Check if you're on the [latest VitePress version](https://github.com/vuejs/vitepress/releases/latest).\n- [x] Follow our [Code of Conduct](https://vuejs.org/about/coc.html)\n- [x] Read the [docs](https://vitepress.dev).\n- [x] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.",[2965],{"name":2895,"color":2896},4766,"MPA claims to be no-JS-by-default, but isn't, and there is no real way to make it no-JS","2025-05-29T08:35:15Z","https://github.com/vuejs/vitepress/issues/4766",0.7314694,["Reactive",2972],{},["Set"],["ShallowReactive",2975],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fP21-ryLEUwptWDtzoi7qssiIKVOZyq_Kt904q0Dj-hs":-1},"/vuejs/vitepress/1643"]