From 34e88f986485661828993392306bad8eef6e4cb6 Mon Sep 17 00:00:00 2001 From: Acbox liu <850625057@qq.com> Date: Tue, 3 Dec 2024 16:22:12 +0800 Subject: [PATCH] release(extension-code): v0.7.0-beta.1 --- extensions/code/src/index.vue | 10 ++++++---- tsconfig.json | 4 ++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/extensions/code/src/index.vue b/extensions/code/src/index.vue index c2064d5..7f4836a 100644 --- a/extensions/code/src/index.vue +++ b/extensions/code/src/index.vue @@ -24,13 +24,15 @@ const codes = slots.default .map((vnode) => vnode.children) .join("") : ""; -const content = ref( - await codeToHtml(codes, { +const content = ref(""); + +(async () => { + content.value = await codeToHtml(codes, { ...options.shikiOptions, lang: options.lang, theme: options.theme, - }), -); + }); +})();