XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet
公开
关注 0 Fork 0 Star 0
返回提交历史

XFEstudio/bilibili-API-collect

add search plugin (#816)

d6d1787
renmu123 <1101022351@qq.com>
提交于

代码差异

3 个文件 +60 -41
Modified .vuepress/config.js +45 -40
@@ -1,46 +1,51 @@
1 import { defaultTheme, defineUserConfig } from 'vuepress'
2 import markdownItTaskLists from 'markdown-it-task-lists'
1 import { defaultTheme, defineUserConfig } from "vuepress";
2 import markdownItTaskLists from "markdown-it-task-lists";
3 3 import { copyCodePlugin } from "vuepress-plugin-copy-code2";
4 import { searchPlugin } from "@vuepress/plugin-search";
4 5
5 6 export default defineUserConfig({
6 base: "/bilibili-API-collect/",
7 lang: 'zh-CN',
8 title: "BAC Document",
9 description: "社区开源的第三方哔哩哔哩 API 文档",
10 head: [
11 ['link', { rel: 'icon', href: '/logo2.jpg' }]
12 ],
13 locales: {
14 '/': {
15 lang: 'zh-CN',
16 },
7 base: "/bilibili-API-collect/",
8 lang: "zh-CN",
9 title: "BAC Document",
10 description: "社区开源的第三方哔哩哔哩 API 文档",
11 head: [["link", { rel: "icon", href: "/logo2.jpg" }]],
12 locales: {
13 "/": {
14 lang: "zh-CN",
17 15 },
18 theme: defaultTheme({
19 logo: '/logo2.jpg',
20 navbar: [
21 { text: '首页', link: '/' },
22 { text: '目录', link: '/#🍴目录' },
23 { text: '贡献指南', link: '/CONTRIBUTING.html' },
24 {
25 text: '相关社群',
26 children: [
27 { text: 'QQ交流群', link: 'http://qm.qq.com/cgi-bin/qm/qr?_wv=1027&k=2rRJXK3zgU5yi3e_4rNLeJYUjMLzw_Jj&authKey=L%2FN3EfZXo3QFjEuHq4ifTgh%2F384UmrYpjl7dbYPhYHtznhfJWxkymxQKObQunmEQ&noverify=0&group_code=560304737' },
28 { text: 'Telegram交流群', link: 'https://t.me/bilibili_API_collect_community' }
29 ]
30 }
16 },
17 theme: defaultTheme({
18 logo: "/logo2.jpg",
19 navbar: [
20 { text: "首页", link: "/" },
21 { text: "目录", link: "/#🍴目录" },
22 { text: "贡献指南", link: "/CONTRIBUTING.html" },
23 {
24 text: "相关社群",
25 children: [
26 {
27 text: "QQ交流群",
28 link: "http://qm.qq.com/cgi-bin/qm/qr?_wv=1027&k=2rRJXK3zgU5yi3e_4rNLeJYUjMLzw_Jj&authKey=L%2FN3EfZXo3QFjEuHq4ifTgh%2F384UmrYpjl7dbYPhYHtznhfJWxkymxQKObQunmEQ&noverify=0&group_code=560304737",
29 },
30 {
31 text: "Telegram交流群",
32 link: "https://t.me/bilibili_API_collect_community",
33 },
31 34 ],
32 sidebar: 'auto',
33 repo: 'SocialSisterYi/bilibili-API-collect',
34 docsBranch: 'master',
35 editLinkText: '在 GitHub 上编辑此页',
36 }),
37 plugins: [copyCodePlugin({})],
38 markdown: {
39 code: {
40 lineNumbers: true
41 }
35 },
36 ],
37 sidebar: "auto",
38 repo: "SocialSisterYi/bilibili-API-collect",
39 docsBranch: "master",
40 editLinkText: "在 GitHub 上编辑此页",
41 }),
42 plugins: [copyCodePlugin({}), searchPlugin({})],
43 markdown: {
44 code: {
45 lineNumbers: true,
42 46 },
43 extendsMarkdown: (md) => {
44 md.use(markdownItTaskLists)
45 }
46 })
47 },
48 extendsMarkdown: (md) => {
49 md.use(markdownItTaskLists);
50 },
51 });
Modified package.json +2 -1
@@ -14,6 +14,7 @@
14 14 "devDependencies": {
15 15 "vuepress": "2.0.0-beta.67",
16 16 "vuepress-plugin-copy-code2": "2.0.0-beta.237",
17 "vuepress-vite": "2.0.0-beta.67"
17 "vuepress-vite": "2.0.0-beta.67",
18 "@vuepress/plugin-search": "^2.0.0-beta.67"
18 19 }
19 20 }
Modified yarn.lock +13 -0
@@ -553,6 +553,19 @@
553 553 "@vuepress/core" "2.0.0-beta.67"
554 554 prismjs "^1.29.0"
555 555
556 "@vuepress/plugin-search@^2.0.0-beta.67":
557 version "2.0.0-beta.67"
558 resolved "https://registry.yarnpkg.com/@vuepress/plugin-search/-/plugin-search-2.0.0-beta.67.tgz#f903a10c360de0180517026b2bd992c2e33b9167"
559 integrity sha512-oju9DK2zQE7PqP7EXm/c0ekoG0clLSn4h6Y7DvgbXJRmonM42oHHj3DdC/eGtyLhTUGuD7mw93Svj2uaC556Nw==
560 dependencies:
561 "@vuepress/client" "2.0.0-beta.67"
562 "@vuepress/core" "2.0.0-beta.67"
563 "@vuepress/shared" "2.0.0-beta.67"
564 "@vuepress/utils" "2.0.0-beta.67"
565 chokidar "^3.5.3"
566 vue "^3.3.4"
567 vue-router "^4.2.4"
568
556 569 "@vuepress/plugin-theme-data@2.0.0-beta.67":
557 570 version "2.0.0-beta.67"
558 571 resolved "https://registry.npmjs.org/@vuepress/plugin-theme-data/-/plugin-theme-data-2.0.0-beta.67.tgz#e2258b6b71096436dc89629a5a4b82b7bca4d275"