From 81870e0c23a2b711abe263b4b3a2674a926b7f6d Mon Sep 17 00:00:00 2001 From: pengzhanbo Date: Sat, 27 Jan 2024 01:34:51 +0800 Subject: [PATCH] perf: bump vuepress to `2.0.0-rc.2` --- .vscode/settings.json | 3 + docs/.vuepress/config.ts | 7 +- docs/package.json | 14 +- package.json | 2 +- ...h => @vuepress__markdown@2.0.0-rc.2.patch} | 4 +- plugins/plugin-auto-frontmatter/package.json | 6 +- .../src/node/plugin.ts | 4 +- .../src/node/readFiles.ts | 2 +- plugins/plugin-baidu-tongji/package.json | 4 +- .../plugin-baidu-tongji/src/node/plugin.ts | 2 +- plugins/plugin-blog-data/package.json | 6 +- plugins/plugin-blog-data/src/client/config.ts | 5 +- plugins/plugin-blog-data/src/node/plugin.ts | 4 +- .../src/node/prepareBlogData.ts | 2 +- plugins/plugin-blog-data/src/shared/index.ts | 2 +- plugins/plugin-blog-data/tsconfig.build.json | 2 +- plugins/plugin-caniuse/package.json | 6 +- .../plugin-caniuse/src/client/clientConfig.ts | 5 +- plugins/plugin-caniuse/src/node/plugin.ts | 4 +- plugins/plugin-content-update/package.json | 6 +- .../src/client/clientConfig.ts | 5 +- .../src/client/components/Content.ts | 2 +- .../plugin-content-update/src/node/plugin.ts | 4 +- plugins/plugin-copy-code/package.json | 7 +- .../src/client/clientConfig.ts | 5 +- plugins/plugin-copy-code/src/node/plugin.ts | 4 +- plugins/plugin-iconify/package.json | 7 +- .../plugin-iconify/src/client/clientConfig.ts | 5 +- .../src/client/components/Iconify.vue | 2 +- plugins/plugin-iconify/src/node/plugin.ts | 4 +- plugins/plugin-netlify-functions/package.json | 6 +- .../src/node/extendsBundlerOptions.ts | 2 +- .../src/node/netlify/initFunctions.ts | 4 +- .../src/node/netlify/netlifyConfig.ts | 4 +- .../src/node/netlify/netlifyServer.ts | 2 +- .../src/node/plugin.ts | 2 +- .../src/node/useNetlifyFunctionsPlugins.ts | 4 +- .../src/node/utils/readFileList.ts | 2 +- plugins/plugin-notes-data/package.json | 7 +- .../src/client/clientConfig.ts | 5 +- plugins/plugin-notes-data/src/node/plugin.ts | 4 +- .../src/node/prepareNotesData.ts | 4 +- plugins/plugin-notes-data/tsconfig.build.json | 2 +- plugins/plugin-page-collection/package.json | 7 +- .../src/client/clientConfig.ts | 5 +- .../plugin-page-collection/src/node/plugin.ts | 4 +- plugins/plugin-shikiji/package.json | 5 +- plugins/plugin-shikiji/src/node/highlight.ts | 2 +- .../plugin-shikiji/src/node/shikijiPlugin.ts | 2 +- pnpm-lock.yaml | 2121 +++++++---------- theme/package.json | 39 +- theme/src/client/components/BackToTop.vue | 2 +- theme/src/client/components/Blog.vue | 2 +- .../src/client/components/DocOutlineItem.vue | 2 +- .../src/client/components/Flyout/MenuLink.vue | 2 +- theme/src/client/components/Friends.vue | 2 +- theme/src/client/components/Home.vue | 2 +- theme/src/client/components/LocalNav.vue | 2 +- .../components/LocalNavOutlineDropdown.vue | 2 +- theme/src/client/components/Nav/NavBar.vue | 2 +- .../client/components/Nav/NavBarMenuGroup.vue | 2 +- .../client/components/Nav/NavBarMenuLink.vue | 2 +- .../src/client/components/Nav/NavBarTitle.vue | 5 +- theme/src/client/components/Nav/index.vue | 2 +- theme/src/client/components/Page.vue | 2 +- theme/src/client/components/PageAside.vue | 11 +- theme/src/client/components/PageAsideItem.vue | 15 +- theme/src/client/components/PageFooter.vue | 6 + theme/src/client/components/PageMeta.vue | 2 +- theme/src/client/components/VImage.vue | 2 +- theme/src/client/composables/blog.ts | 2 +- theme/src/client/composables/langs.ts | 2 +- theme/src/client/composables/locale.ts | 2 +- theme/src/client/composables/page.ts | 6 +- theme/src/client/composables/readingTime.ts | 2 +- theme/src/client/composables/sidebar.ts | 4 +- .../useResolveRouteWithRedirect.ts | 2 +- theme/src/client/config.ts | 5 +- theme/src/client/layouts/Layout.vue | 2 +- theme/src/client/layouts/NotFound.vue | 2 +- theme/src/client/utils/normalizeLink.ts | 2 +- theme/src/client/utils/resolveEditLink.ts | 2 +- theme/src/client/utils/resolveRepoType.ts | 2 +- theme/src/client/utils/socialIcons.ts | 2 + theme/src/node/autoFrontmatter.ts | 6 +- theme/src/node/container.ts | 2 +- theme/src/node/defaultOptions.ts | 2 +- theme/src/node/plugins.ts | 2 +- theme/src/node/resolveLocaleOptions.ts | 2 +- theme/src/node/searchPluginOptions.ts | 2 +- theme/src/node/setupPages.ts | 6 +- theme/src/node/theme.ts | 4 +- theme/src/node/utils.ts | 2 +- theme/src/shared/options/locale.ts | 4 +- theme/tsconfig.build.json | 2 +- 95 files changed, 1042 insertions(+), 1464 deletions(-) rename patches/{@vuepress__markdown@2.0.0-rc.0.patch => @vuepress__markdown@2.0.0-rc.2.patch} (83%) diff --git a/.vscode/settings.json b/.vscode/settings.json index a46c7cc3..7b2806a2 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -8,6 +8,9 @@ "[markdown]": { "files.trimTrailingWhitespace": false }, + "[typescript]": { + "editor.defaultFormatter": "Vue.volar" + }, "css.validate": false, "scss.validate": false, "less.validate": false, diff --git a/docs/.vuepress/config.ts b/docs/.vuepress/config.ts index 20a13535..77e42562 100644 --- a/docs/.vuepress/config.ts +++ b/docs/.vuepress/config.ts @@ -1,8 +1,8 @@ import * as path from 'node:path' import process from 'node:process' +import { defineUserConfig } from 'vuepress' import { viteBundler } from '@vuepress/bundler-vite' import { webpackBundler } from '@vuepress/bundler-webpack' -import { defineUserConfig } from '@vuepress/cli' import { theme } from './theme.js' export default defineUserConfig({ @@ -14,7 +14,10 @@ export default defineUserConfig({ '/': { title: 'Plume主题', description: '', lang: 'zh-CN' }, '/en/': { title: 'Plume Theme', description: '', lang: 'en-US' }, }, - bundler: process.env.DOCS_BUNDLER === 'webpack' ? webpackBundler() : viteBundler(), + + // specify bundler via environment variable + bundler: + process.env.DOCS_BUNDLER === 'webpack' ? webpackBundler() : viteBundler(), theme, }) diff --git a/docs/package.json b/docs/package.json index 2c874353..6e32d7ed 100644 --- a/docs/package.json +++ b/docs/package.json @@ -3,17 +3,17 @@ "type": "module", "private": true, "scripts": { - "docs:build": "vuepress-cli build --clean-cache", + "docs:build": "vuepress build --clean-cache", "docs:clean": "rimraf .vuepress/.temp .vuepress/.cache .vuepress/dist", - "docs:dev": "vuepress-cli dev --clean-cache --clean-temp", + "docs:dev": "vuepress dev --clean-cache --clean-temp", "docs:serve": "anywhere -s -h localhost -d .vuepress/dist" }, + "peerDependencies": { + "vuepress": "2.0.0-rc.2" + }, "dependencies": { - "@vuepress/bundler-vite": "2.0.0-rc.0", - "@vuepress/bundler-webpack": "2.0.0-rc.0", - "@vuepress/cli": "2.0.0-rc.0", - "@vuepress/client": "2.0.0-rc.0", - "@vuepress/utils": "2.0.0-rc.0", + "@vuepress/bundler-vite": "2.0.0-rc.2", + "@vuepress/bundler-webpack": "2.0.0-rc.2", "anywhere": "^1.6.0", "sass": "^1.70.0", "sass-loader": "^14.0.0", diff --git a/package.json b/package.json index 9a57039b..0fb72656 100644 --- a/package.json +++ b/package.json @@ -62,7 +62,7 @@ }, "pnpm": { "patchedDependencies": { - "@vuepress/markdown@2.0.0-rc.0": "patches/@vuepress__markdown@2.0.0-rc.0.patch" + "@vuepress/markdown@2.0.0-rc.2": "patches/@vuepress__markdown@2.0.0-rc.2.patch" } }, "lint-staged": { diff --git a/patches/@vuepress__markdown@2.0.0-rc.0.patch b/patches/@vuepress__markdown@2.0.0-rc.2.patch similarity index 83% rename from patches/@vuepress__markdown@2.0.0-rc.0.patch rename to patches/@vuepress__markdown@2.0.0-rc.2.patch index c091b50e..7a5049e1 100644 --- a/patches/@vuepress__markdown@2.0.0-rc.0.patch +++ b/patches/@vuepress__markdown@2.0.0-rc.2.patch @@ -1,8 +1,8 @@ diff --git a/dist/index.js b/dist/index.js -index 996b0d16dac39667cc25496e52adcc9dd2b2befa..a4c9f5ba3a20967d9a561fcc73178d9e84f48279 100644 +index de136bbd25d01677b7b86b6654b780765b9b7cec..b0ff18b8888fe4e691e8c8c2ee3db6ba9fd35ed2 100644 --- a/dist/index.js +++ b/dist/index.js -@@ -245,7 +245,7 @@ var codePlugin = (md, { +@@ -267,7 +267,7 @@ var codePlugin = (md, { const info = token.info ? md.utils.unescapeAll(token.info).trim() : ""; const language = resolveLanguage(info); const languageClass = `${options.langPrefix}${language.name}`; diff --git a/plugins/plugin-auto-frontmatter/package.json b/plugins/plugin-auto-frontmatter/package.json index bde82b0a..bd98b874 100644 --- a/plugins/plugin-auto-frontmatter/package.json +++ b/plugins/plugin-auto-frontmatter/package.json @@ -31,10 +31,10 @@ "copy": "cpx \"src/**/*.{d.ts,vue,css,scss,jpg,png}\" lib", "ts": "tsc -b tsconfig.build.json" }, + "peerDependencies": { + "vuepress": "2.0.0-rc.2" + }, "dependencies": { - "@vuepress/core": "2.0.0-rc.0", - "@vuepress/shared": "2.0.0-rc.0", - "@vuepress/utils": "2.0.0-rc.0", "chokidar": "^3.5.3", "create-filter": "^1.0.1", "fast-glob": "^3.3.2", diff --git a/plugins/plugin-auto-frontmatter/src/node/plugin.ts b/plugins/plugin-auto-frontmatter/src/node/plugin.ts index 4fdee4ab..b58dc5b6 100644 --- a/plugins/plugin-auto-frontmatter/src/node/plugin.ts +++ b/plugins/plugin-auto-frontmatter/src/node/plugin.ts @@ -1,5 +1,5 @@ -import { fs } from '@vuepress/utils' -import type { Plugin } from '@vuepress/core' +import { fs } from 'vuepress/utils' +import type { Plugin } from 'vuepress/core' import chokidar from 'chokidar' import { createFilter } from 'create-filter' import grayMatter from 'gray-matter' diff --git a/plugins/plugin-auto-frontmatter/src/node/readFiles.ts b/plugins/plugin-auto-frontmatter/src/node/readFiles.ts index 391c92ab..ed4b2e07 100644 --- a/plugins/plugin-auto-frontmatter/src/node/readFiles.ts +++ b/plugins/plugin-auto-frontmatter/src/node/readFiles.ts @@ -1,4 +1,4 @@ -import { fs, path } from '@vuepress/utils' +import { fs, path } from 'vuepress/utils' import fg from 'fast-glob' import type { MarkdownFile } from '../shared/index.js' diff --git a/plugins/plugin-baidu-tongji/package.json b/plugins/plugin-baidu-tongji/package.json index 6a2baaa3..f7337b3e 100644 --- a/plugins/plugin-baidu-tongji/package.json +++ b/plugins/plugin-baidu-tongji/package.json @@ -31,8 +31,8 @@ "copy": "cpx \"src/**/*.{d.ts,vue,css,scss,jpg,png}\" lib", "ts": "tsc -b tsconfig.build.json" }, - "dependencies": { - "@vuepress/core": "2.0.0-rc.0" + "peerDependencies": { + "vuepress": "2.0.0-rc.2" }, "publishConfig": { "access": "public" diff --git a/plugins/plugin-baidu-tongji/src/node/plugin.ts b/plugins/plugin-baidu-tongji/src/node/plugin.ts index 80e8eb24..478830fa 100644 --- a/plugins/plugin-baidu-tongji/src/node/plugin.ts +++ b/plugins/plugin-baidu-tongji/src/node/plugin.ts @@ -1,4 +1,4 @@ -import type { Plugin } from '@vuepress/core' +import type { Plugin } from 'vuepress/core' export interface BaiduTongjiOptions { key?: string diff --git a/plugins/plugin-blog-data/package.json b/plugins/plugin-blog-data/package.json index 4f936dda..2d2627cf 100644 --- a/plugins/plugin-blog-data/package.json +++ b/plugins/plugin-blog-data/package.json @@ -35,11 +35,11 @@ "copy": "cpx \"src/**/*.{d.ts,vue,css,scss,jpg,png}\" lib", "ts": "tsc -b tsconfig.build.json" }, + "peerDependencies": { + "vuepress": "2.0.0-rc.2" + }, "dependencies": { "@vue/devtools-api": "6.5.1", - "@vuepress/client": "2.0.0-rc.0", - "@vuepress/core": "2.0.0-rc.0", - "@vuepress/utils": "2.0.0-rc.0", "chokidar": "^3.5.3", "create-filter": "^1.0.1", "vue": "^3.4.15" diff --git a/plugins/plugin-blog-data/src/client/config.ts b/plugins/plugin-blog-data/src/client/config.ts index 53d15727..09d2f231 100644 --- a/plugins/plugin-blog-data/src/client/config.ts +++ b/plugins/plugin-blog-data/src/client/config.ts @@ -1,5 +1,6 @@ import { setupDevtoolsPlugin } from '@vue/devtools-api' -import { defineClientConfig } from '@vuepress/client' +import { defineClientConfig } from 'vuepress/client' +import type { ClientConfig } from 'vuepress/client' import { useBlogPostData } from './composables/index.js' declare const __VUE_PROD_DEVTOOLS__: boolean @@ -66,4 +67,4 @@ export default defineClientConfig({ ) } }, -}) +}) as ClientConfig diff --git a/plugins/plugin-blog-data/src/node/plugin.ts b/plugins/plugin-blog-data/src/node/plugin.ts index ab811115..5d6ac8bd 100644 --- a/plugins/plugin-blog-data/src/node/plugin.ts +++ b/plugins/plugin-blog-data/src/node/plugin.ts @@ -1,5 +1,5 @@ -import type { Plugin } from '@vuepress/core' -import { getDirname, path } from '@vuepress/utils' +import type { Plugin } from 'vuepress/core' +import { getDirname, path } from 'vuepress/utils' import chokidar from 'chokidar' import { createFilter } from 'create-filter' import { preparedBlogData } from './prepareBlogData.js' diff --git a/plugins/plugin-blog-data/src/node/prepareBlogData.ts b/plugins/plugin-blog-data/src/node/prepareBlogData.ts index da91e40e..e712ab69 100644 --- a/plugins/plugin-blog-data/src/node/prepareBlogData.ts +++ b/plugins/plugin-blog-data/src/node/prepareBlogData.ts @@ -1,4 +1,4 @@ -import type { App, Page } from '@vuepress/core' +import type { App, Page } from 'vuepress/core' import type { BlogPostData, BlogPostDataItem } from '../shared/index.js' import type { PluginOption } from './plugin.js' diff --git a/plugins/plugin-blog-data/src/shared/index.ts b/plugins/plugin-blog-data/src/shared/index.ts index 8ab5f1f9..86af918c 100644 --- a/plugins/plugin-blog-data/src/shared/index.ts +++ b/plugins/plugin-blog-data/src/shared/index.ts @@ -1,4 +1,4 @@ -import type { Page } from '@vuepress/core' +import type { Page } from 'vuepress/core' export interface BlogDataPluginOptions { include?: string | string[] diff --git a/plugins/plugin-blog-data/tsconfig.build.json b/plugins/plugin-blog-data/tsconfig.build.json index 1c7921a2..3f0244f8 100644 --- a/plugins/plugin-blog-data/tsconfig.build.json +++ b/plugins/plugin-blog-data/tsconfig.build.json @@ -6,7 +6,7 @@ "paths": { "@internal/blogData": ["./src/client/blogPostData.d.ts"] }, - "types": ["@vuepress/client/types", "vite/client", "webpack-env"], + "types": ["vuepress/client-types", "vite/client", "webpack-env"], "outDir": "./lib" }, "include": ["./src"] diff --git a/plugins/plugin-caniuse/package.json b/plugins/plugin-caniuse/package.json index 45acac29..eb277964 100644 --- a/plugins/plugin-caniuse/package.json +++ b/plugins/plugin-caniuse/package.json @@ -41,10 +41,10 @@ "clean": "rimraf lib *.tsbuildinfo", "ts": "tsc -b tsconfig.build.json" }, + "peerDependencies": { + "vuepress": "2.0.0-rc.2" + }, "dependencies": { - "@vuepress/client": "2.0.0-rc.0", - "@vuepress/core": "2.0.0-rc.0", - "@vuepress/utils": "2.0.0-rc.0", "markdown-it-container": "^4.0.0" }, "devDependencies": { diff --git a/plugins/plugin-caniuse/src/client/clientConfig.ts b/plugins/plugin-caniuse/src/client/clientConfig.ts index 962fa046..cf788296 100644 --- a/plugins/plugin-caniuse/src/client/clientConfig.ts +++ b/plugins/plugin-caniuse/src/client/clientConfig.ts @@ -1,4 +1,5 @@ -import { defineClientConfig } from '@vuepress/client' +import { defineClientConfig } from 'vuepress/client' +import type { ClientConfig } from 'vuepress/client' import type { CanIUseMode } from '../shared/index.js' import { resolveCanIUse } from './resolveCanIUse.js' @@ -17,4 +18,4 @@ export default defineClientConfig({ resolveCanIUse() }) }, -}) +}) as ClientConfig diff --git a/plugins/plugin-caniuse/src/node/plugin.ts b/plugins/plugin-caniuse/src/node/plugin.ts index ce9d2f89..55feb3c9 100644 --- a/plugins/plugin-caniuse/src/node/plugin.ts +++ b/plugins/plugin-caniuse/src/node/plugin.ts @@ -1,5 +1,5 @@ -import type { Plugin, PluginObject } from '@vuepress/core' -import { getDirname, path } from '@vuepress/utils' +import type { Plugin, PluginObject } from 'vuepress/core' +import { getDirname, path } from 'vuepress/utils' import type Token from 'markdown-it/lib/token.js' import container from 'markdown-it-container' import type { CanIUseMode, CanIUsePluginOptions } from '../shared/index.js' diff --git a/plugins/plugin-content-update/package.json b/plugins/plugin-content-update/package.json index 81cba216..3038e78a 100644 --- a/plugins/plugin-content-update/package.json +++ b/plugins/plugin-content-update/package.json @@ -35,10 +35,10 @@ "copy": "cpx \"src/**/*.{d.ts,vue,css,scss,jpg,png}\" lib", "ts": "tsc -b tsconfig.build.json" }, + "peerDependencies": { + "vuepress": "2.0.0-rc.2" + }, "dependencies": { - "@vuepress/client": "2.0.0-rc.0", - "@vuepress/core": "2.0.0-rc.0", - "@vuepress/utils": "2.0.0-rc.0", "vue": "^3.4.15", "vue-router": "4.2.5" }, diff --git a/plugins/plugin-content-update/src/client/clientConfig.ts b/plugins/plugin-content-update/src/client/clientConfig.ts index db419180..bad236a4 100644 --- a/plugins/plugin-content-update/src/client/clientConfig.ts +++ b/plugins/plugin-content-update/src/client/clientConfig.ts @@ -1,4 +1,5 @@ -import { defineClientConfig } from '@vuepress/client' +import { defineClientConfig } from 'vuepress/client' +import type { ClientConfig } from 'vuepress/client' import { Content } from './components/Content.js' export default defineClientConfig({ @@ -8,4 +9,4 @@ export default defineClientConfig({ app.component('Content', Content) }, -}) +}) as ClientConfig diff --git a/plugins/plugin-content-update/src/client/components/Content.ts b/plugins/plugin-content-update/src/client/components/Content.ts index d0659aa8..d02a7987 100644 --- a/plugins/plugin-content-update/src/client/components/Content.ts +++ b/plugins/plugin-content-update/src/client/components/Content.ts @@ -1,6 +1,6 @@ import { pagesComponents } from '@internal/pagesComponents' import { computed, defineComponent, h } from 'vue' -import { usePageData } from '@vuepress/client' +import { usePageData } from 'vuepress/client' import { runCallbacks } from '../composables/index.js' declare const __VUEPRESS_DEV__: boolean diff --git a/plugins/plugin-content-update/src/node/plugin.ts b/plugins/plugin-content-update/src/node/plugin.ts index 02c61177..6d041dee 100644 --- a/plugins/plugin-content-update/src/node/plugin.ts +++ b/plugins/plugin-content-update/src/node/plugin.ts @@ -1,5 +1,5 @@ -import type { Plugin } from '@vuepress/core' -import { getDirname, path } from '@vuepress/utils' +import type { Plugin } from 'vuepress/core' +import { getDirname, path } from 'vuepress/utils' const __dirname = getDirname(import.meta.url) diff --git a/plugins/plugin-copy-code/package.json b/plugins/plugin-copy-code/package.json index 9906bd26..68df291b 100644 --- a/plugins/plugin-copy-code/package.json +++ b/plugins/plugin-copy-code/package.json @@ -35,12 +35,11 @@ "copy": "cpx \"src/**/*.{d.ts,vue,css,scss,jpg,png}\" lib", "ts": "tsc -b tsconfig.build.json" }, + "peerDependencies": { + "vuepress": "2.0.0-rc.2" + }, "dependencies": { "@vuepress-plume/plugin-content-update": "workspace:*", - "@vuepress/client": "2.0.0-rc.0", - "@vuepress/core": "2.0.0-rc.0", - "@vuepress/shared": "2.0.0-rc.0", - "@vuepress/utils": "2.0.0-rc.0", "vue": "^3.4.15" }, "publishConfig": { diff --git a/plugins/plugin-copy-code/src/client/clientConfig.ts b/plugins/plugin-copy-code/src/client/clientConfig.ts index b0e3727a..3a44ee3f 100644 --- a/plugins/plugin-copy-code/src/client/clientConfig.ts +++ b/plugins/plugin-copy-code/src/client/clientConfig.ts @@ -1,4 +1,5 @@ -import { defineClientConfig } from '@vuepress/client' +import { defineClientConfig } from 'vuepress/client' +import type { ClientConfig } from 'vuepress/client' import { setupCopyCode } from './setupCopyCode.js' import './styles/button.css' @@ -7,4 +8,4 @@ export default defineClientConfig({ setup() { setupCopyCode() }, -}) +}) as ClientConfig diff --git a/plugins/plugin-copy-code/src/node/plugin.ts b/plugins/plugin-copy-code/src/node/plugin.ts index 5e1acc1d..1f8bd3fd 100644 --- a/plugins/plugin-copy-code/src/node/plugin.ts +++ b/plugins/plugin-copy-code/src/node/plugin.ts @@ -1,5 +1,5 @@ -import type { Plugin } from '@vuepress/core' -import { getDirname, path } from '@vuepress/utils' +import type { Plugin } from 'vuepress/core' +import { getDirname, path } from 'vuepress/utils' import type { CopyCodeOptions } from '../shared/index.js' const __dirname = getDirname(import.meta.url) diff --git a/plugins/plugin-iconify/package.json b/plugins/plugin-iconify/package.json index b7d59f1a..f808b272 100644 --- a/plugins/plugin-iconify/package.json +++ b/plugins/plugin-iconify/package.json @@ -35,12 +35,11 @@ "copy": "cpx \"src/**/*.{d.ts,vue,css,scss,jpg,png}\" lib", "ts": "tsc -b tsconfig.build.json" }, + "peerDependencies": { + "vuepress": "2.0.0-rc.2" + }, "dependencies": { "@iconify/vue": "^4.1.1", - "@vuepress/client": "2.0.0-rc.0", - "@vuepress/core": "2.0.0-rc.0", - "@vuepress/shared": "2.0.0-rc.0", - "@vuepress/utils": "2.0.0-rc.0", "vue": "^3.4.15" }, "publishConfig": { diff --git a/plugins/plugin-iconify/src/client/clientConfig.ts b/plugins/plugin-iconify/src/client/clientConfig.ts index 03483da1..bd9bc0ec 100644 --- a/plugins/plugin-iconify/src/client/clientConfig.ts +++ b/plugins/plugin-iconify/src/client/clientConfig.ts @@ -1,4 +1,5 @@ -import { defineClientConfig } from '@vuepress/client' +import { defineClientConfig } from 'vuepress/client' +import type { ClientConfig } from 'vuepress/client' import Iconify from './components/Iconify.vue' declare const __VUEPRESS_PLUGIN_ICONIFY_COMPONENT_NAME__: string @@ -7,4 +8,4 @@ export default defineClientConfig({ const name = __VUEPRESS_PLUGIN_ICONIFY_COMPONENT_NAME__ || 'Iconify' app.component(name, Iconify) }, -}) +}) as ClientConfig diff --git a/plugins/plugin-iconify/src/client/components/Iconify.vue b/plugins/plugin-iconify/src/client/components/Iconify.vue index c57c97c7..977b8dc6 100644 --- a/plugins/plugin-iconify/src/client/components/Iconify.vue +++ b/plugins/plugin-iconify/src/client/components/Iconify.vue @@ -1,6 +1,6 @@