From d2de07005cb9498122df600799b2ae3a0af758bb Mon Sep 17 00:00:00 2001 From: Divyansh Singh <40380293+brc-dd@users.noreply.github.com> Date: Wed, 15 Feb 2023 19:32:18 +0530 Subject: [PATCH] fix: augment vite user config --- src/node/plugin.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/node/plugin.ts b/src/node/plugin.ts index 4eef341aa566..11e29d7e650e 100644 --- a/src/node/plugin.ts +++ b/src/node/plugin.ts @@ -21,6 +21,12 @@ import { staticDataPlugin } from './staticDataPlugin' import { slash } from './utils/slash' import { webFontsPlugin } from './webFontsPlugin' +declare module 'vite' { + interface UserConfig { + vitepress?: SiteConfig + } +} + const hashRE = /\.(\w+)\.js$/ const staticInjectMarkerRE = /\b(const _hoisted_\d+ = \/\*(?:#|@)__PURE__\*\/\s*createStaticVNode)\("(.*)", (\d+)\)/g @@ -131,7 +137,6 @@ export async function createVitePressPlugin( ] } }, - // @ts-ignore vitepress: siteConfig }) return userViteConfig