diff --git a/docs/.vuepress/config.ts b/docs/.vuepress/config.ts index 7c8f7dc5..90bddeb3 100644 --- a/docs/.vuepress/config.ts +++ b/docs/.vuepress/config.ts @@ -2,8 +2,6 @@ import {defineUserConfig} from "vuepress"; import theme from "./theme.js"; import {commentPlugin} from "vuepress-plugin-comment2"; import {mdEnhancePlugin} from "vuepress-plugin-md-enhance"; -import {searchProPlugin} from "vuepress-plugin-search-pro"; -import {cut} from "nodejs-jieba"; export default defineUserConfig({ dest: "./dist", @@ -21,17 +19,6 @@ export default defineUserConfig({ // 启用图片大小 imgSize: true, }), - //加强中文搜索 - searchProPlugin({ - // 配置选项 - // 索引全部内容 - indexContent: true, - indexOptions: { - // 使用 nodejs-jieba 进行分词 - tokenize: (text, fieldName) => - fieldName === "id" ? [text] : cut(text, true), - }, - }), // https://plugin-comment2.vuejs.press/zh/config/giscus.html#darktheme commentPlugin({ provider: "Giscus", diff --git a/package.json b/package.json index e856178e..3bf64746 100644 --- a/package.json +++ b/package.json @@ -18,11 +18,11 @@ "dependencies": { "@vuepress/client": "2.0.0-rc.0", "@vuepress/utils": "2.0.0-rc.0", + "@vuepress/plugin-search": "2.0.0-rc.0", "husky": "8.0.3", "markdownlint-cli2": "0.11.0", "mathjax-full": "3.2.2", "nano-staged": "0.8.0", - "vuepress-plugin-search-pro": "2.0.0-rc.13", "nodejs-jieba": "0.1.2", "prettier": "3.1.1", "vue": "^3.4.13",