From acfe97f60872d251c75c5985ca9841f84392850d Mon Sep 17 00:00:00 2001 From: Divyansh Singh <40380293+brc-dd@users.noreply.github.com> Date: Tue, 29 Oct 2024 21:47:25 +0530 Subject: [PATCH] fix: dispose mdit instance on manual restart too --- src/node/shortcuts.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/node/shortcuts.ts b/src/node/shortcuts.ts index 84aa03ec8d81..f8db986cf451 100644 --- a/src/node/shortcuts.ts +++ b/src/node/shortcuts.ts @@ -1,6 +1,7 @@ import type { ViteDevServer } from 'vite' import c from 'picocolors' import { clearCache } from './markdownToVue' +import { disposeMdItInstance } from './markdown/markdown' type CreateDevServer = () => Promise @@ -81,6 +82,7 @@ const SHORTCUTS: CLIShortcut[] = [ clear: true, timestamp: true }) + disposeMdItInstance() clearCache() await server.close() await createDevServer()