\r\n\r\n::: zh-CN\r\n中文\r\n:::\r\n\r\n::: en\r\nEnglish\r\n:::\r\n```\r\n\r\nThis reduces maintenance costs.\r\n\r\nI came up with a very low cost implementation - [CSS-I18N](https://github.com/valaxyjs/css-i18n)\r\nAnd I implemented it in my own project [valaxy](https://github.com/YunYouJun/valaxy).\r\n\r\nIt works well. You can preview it [here](https://valaxy.site/guide/i18n).\r\nAnd this is my implementation: [How to realize CSS i18n?](https://valaxy.site/posts/i18n#css-i18n-another-solution)\r\n\r\n---\r\n\r\nIt is very cost-effective and I hope to integrate it with vitepress.\r\nIf you agree with my proposal, please let me know and I can create a PR for vitepress.\r\n\r\n### Describe alternatives you've considered\r\n\r\n_No response_\r\n\r\n### Additional context\r\n\r\n_No response_\r\n\r\n### Validations\r\n\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] Read the [Contributing Guidelines](https://github.com/vuejs/vitepress/blob/main/.github/contributing.md).\r\n- [X] Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.",[2906],{"name":2883,"color":2884},3047,"CSS i18n in one page","2025-03-02T18:10:37Z","https://github.com/vuejs/vitepress/issues/3047",0.7617244,{"description":2913,"labels":2914,"number":2916,"owner":2869,"repository":2870,"state":2871,"title":2917,"updated_at":2918,"url":2919,"score":2920},"### Is your feature request related to a problem? Please describe.\r\n\r\nVite team has created a great repository to list the plugins for Vite: https://github.com/vitejs/awesome-vite\r\n\r\nVuePress did receive the same attention: https://github.com/vuepress/awesome-vuepress\r\nThe same goes on if we think of other projects. Example: https://github.com/stylelint/awesome-stylelint\r\n\r\nThere are many great plugins coming out for VitePress, but it is not easy to find them, since npm registry is not easy to search... the same applies to GitHub as a whole...\r\n\r\nAs long as I know, there are 2 \"awesome-vitepress\" repositories of sort, but they are not updated, the owners are not much online, and actually one of the repositories was targeted only for vitepress v1.\r\n\r\nhttps://github.com/logicspark/awesome-vitepress-v1\r\nhttps://github.com/jonsam-ng/awesome-vitepress\r\n\r\n### Describe the solution you'd like\r\n\r\nTo create a repository where we can contribute to the list of VitePress plugins.\r\nThis is a prestige for your own project and also for the plugin authors.\r\n\r\n### Describe alternatives you've considered\r\n\r\n_No response_\r\n\r\n### Additional context\r\n\r\n_No response_\r\n\r\n### Validations\r\n\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] Read the [Contributing Guidelines](https://github.com/vuejs/vitepress/blob/main/.github/contributing.md).\r\n- [X] Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.",[2915],{"name":2883,"color":2884},4059,"Create a \"awesome-vitepress\" repository","2024-09-29T09:06:02Z","https://github.com/vuejs/vitepress/issues/4059",0.76829904,{"description":2922,"labels":2923,"number":2927,"owner":2869,"repository":2870,"state":2928,"title":2929,"updated_at":2930,"url":2931,"score":2932},"### Describe the bug\n\n使用本地搜索,搜索段落中间的中文无法显示结果,如果是英文没有这个问题。如果搜索的中文是段落前面几个字或者挨着标点符号的中文才显示结果\r\n\u003Cimg width=\"851\" alt=\"image\" src=\"https://github.com/vuejs/vitepress/assets/5304020/d0173cac-b32f-40e8-99f8-546d7d24a21a\">\r\n\u003Cimg width=\"1041\" alt=\"image\" src=\"https://github.com/vuejs/vitepress/assets/5304020/cd28bd06-5531-4eed-97f0-a851093c9391\">\r\n\n\n### Reproduction\n\n可以在我的博客https://www.appbeebee.com/尝试搜索段落中间的中文和段落前的中文进行比较\n\n### Expected behavior\n\n希望本地搜索能进行全文中文搜索,而不是仅仅搜索段落前的中文\n\n### System Info\n\n```Text\nmac google chrome\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.",[2924],{"name":2925,"color":2926},"bug: pending triage","e99695",3507,"closed","本地搜索对中文不是很友好","2024-02-04T00:04:52Z","https://github.com/vuejs/vitepress/issues/3507",0.7263668,{"description":2934,"labels":2935,"number":2940,"owner":2869,"repository":2870,"state":2928,"title":2941,"updated_at":2942,"url":2943,"score":2944},"### Is your feature request related to a problem? Please describe.\r\n\r\nHello,\r\n\r\nActually, I have to create a loader for each language, and then import all of them in my vue component.\r\n\r\n```ts\r\n// @ts-expect-error - vitepress types are not available\r\nimport { data as rootData } from '../../data/posts.data'\r\n// @ts-expect-error - vitepress types are not available\r\nimport { data as frData } from '../../data/fr-posts.data'\r\nimport { computed } from 'vue';\r\n\r\nconst data: Record\u003Cstring, any> = {\r\n root: rootData,\r\n fr: frData\r\n}\r\n\r\nconst { localeIndex } = useData()\r\n\r\nconst posts = computed(() => data[localeIndex.value])\r\n```\r\n\r\n### Describe the solution you'd like\r\n\r\nI would like to have to only create a single content loader and based on my locales configuration (and maybe an option) retrive all content.\r\n\r\nFor example: `posts/*.md` should get `posts/*.md` (the root) and `fr/posts/*.md` (the fr locale).\r\n\r\n### Describe alternatives you've considered\r\n\r\n_No response_\r\n\r\n### Additional context\r\n\r\n_No response_\r\n\r\n### Validations\r\n\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] Read the [Contributing Guidelines](https://github.com/vuejs/vitepress/blob/main/.github/contributing.md).\r\n- [X] Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.",[2936,2939],{"name":2937,"color":2938},"has-workaround","1B4515",{"name":2883,"color":2884},4072,"Support i18n in `contentLoader`","2024-10-08T04:44:35Z","https://github.com/vuejs/vitepress/issues/4072",0.72669685,{"description":2946,"labels":2947,"number":2948,"owner":2869,"repository":2870,"state":2928,"title":2949,"updated_at":2950,"url":2951,"score":2952},"I noticed that `VitePress` imports `@vue/shared`, but it appears to only use one of its methods. However, there are more methods available in `@vue/shared`. Should `VitePress` directly import these additional methods from `@vue/shared` to reduce redundancy in the code?\r\n\r\nHere is one case of what I mentioned:\r\n\r\n`vitepress`:\r\nhttps://github.com/vuejs/vitepress/blob/a6a7645e942cc63c57ca5d79da4b76dee76d8a96/src/node/config.ts#L229\r\n\r\n`@vue/shared`:\r\nhttps://github.com/vuejs/core/blob/db374e54c9f5e07324728b85c74eca84e28dd352/packages/shared/src/general.ts#L52\r\n\r\nSeems that can directly use `import { isObject } from '@vue/shared`.",[],3720,"Reuse some of the existing methods in `@vue/shared`","2024-04-28T12:24:53Z","https://github.com/vuejs/vitepress/issues/3720",0.72751427,{"description":2954,"labels":2955,"number":2957,"owner":2869,"repository":2870,"state":2928,"title":2958,"updated_at":2959,"url":2960,"score":2961},"### Describe the bug\n\nMy project add network request, But I need different environment variables control the request address, how should I use env in vite\r\n\r\n[Env Variables](https://vitejs.dev/guide/env-and-mode.html#env-variables)\n\n### Reproduction\n\nNone\n\n### Expected behavior\n\nI want to be able to access `import.meta.env.BASE_URL`, just like the vite project\n\n### System Info\n\n```Text\nSystem:\r\n OS: Windows 11 10.0.22631\r\n CPU: (16) x64 12th Gen Intel(R) Core(TM) i5-12600KF\r\n Memory: 2.31 GB / 31.82 GB\r\n Binaries:\r\n Node: 18.19.0 - D:\\software\\nodejs\\node.EXE\r\n npm: 10.2.3 - D:\\software\\nodejs\\npm.CMD\r\n pnpm: 9.1.1 - ~\\AppData\\Local\\pnpm\\pnpm.CMD\r\n bun: 1.1.3 - ~\\.bun\\bin\\bun.EXE\r\n Browsers:\r\n Edge: Chromium (123.0.2420.97)\r\n Internet Explorer: 11.0.22621.3527\r\n npmPackages:\r\n vitepress: 1.0.2 => 1.0.2\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.",[2956],{"name":2866,"color":2867},3896,"How to using Vite Env Variables?","2024-05-24T04:42:25Z","https://github.com/vuejs/vitepress/issues/3896",0.74361384,{"description":2963,"labels":2964,"number":2968,"owner":2869,"repository":2870,"state":2928,"title":2969,"updated_at":2970,"url":2971,"score":2972},"### Describe the bug\n\n\r\n\r\nno Ctrl+Space autocomplete on anything in the `export default { ... }` block in `theme/index.ts`\r\n\r\n```ts\r\n// https://vitepress.dev/guide/custom-theme\r\nimport { h } from 'vue'\r\nimport Theme from 'vitepress/theme'\r\nimport './style.css'\r\n\r\nexport default {\r\n extends: Theme,\r\n Layout: () => {\r\n return h(Theme.Layout, null, {\r\n // https://vitepress.dev/guide/extending-default-theme#layout-slots\r\n })\r\n },\r\n enhanceApp({ app, router, siteData }) {\r\n // ...\r\n app.\r\n // ^ NO autocomplete here 😢\r\n }\r\n}\r\n```\n\n### Reproduction\n\nhttps://stackblitz.com/edit/vite-bjyf4o?file=.vitepress%2Ftheme%2Findex.ts\n\n### Expected behavior\n\n\r\n\n\n### System Info\n\n```Text\nSystem:\r\n OS: Linux 5.0 undefined\r\n CPU: (2) 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: 9.4.2 - /usr/local/bin/npm\r\n pnpm: 8.9.2 - /usr/local/bin/pnpm\r\n npmPackages:\r\n vitepress: ^1.0.0-rc.22 => 1.0.0-rc.22\n```\n\n\n### Additional context\n\ni think the solution is to add a `satisfies import('vitepress').Theme` or similar in the docs examples and in the `vitepress init` wizard\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":2966,"color":2967},"contribution welcome","11E4B8",3116,"no autocomplete on enhanceApp() or other things in theme/index.ts export default","2023-10-30T00:04:37Z","https://github.com/vuejs/vitepress/issues/3116",0.75077397,["Reactive",2974],{},["Set"],["ShallowReactive",2977],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fu-6fYJOdc8XdwoZ-6H9F_ed7BIdnauZ3F0XiEMO35Cs":-1},"/vuejs/vitepress/3660"]