diff --git a/src/node/plugin.ts b/src/node/plugin.ts index 6f1751e72530..46f8a7e0affb 100644 --- a/src/node/plugin.ts +++ b/src/node/plugin.ts @@ -266,11 +266,8 @@ export function createVitePressPlugin( } }) - // reload the content component - return vuePlugin.handleHotUpdate!({ - ...ctx, - read: () => vueSrc - }) + // overwrite src so vue plugin can handle the HMR + ctx.read = () => vueSrc } } }