From f58743efbca8548e461e9a57f6934c00fc91f684 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=BB=9D=E5=B0=98?= <237809796@qq.com>
Date: Sun, 14 Jun 2026 22:16:07 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D:=20AR-1=20=E6=B5=81=E5=BC=8F?=
=?UTF-8?q?=20Markdown=20=E5=85=A8=E9=87=8F=E9=87=8D=E8=A7=A3=E6=9E=90?=
=?UTF-8?q?=E6=8E=89=E5=B8=A7?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
renderMd 加 isStreaming 参数:流式态(streaming 中 currentText)纯文本(escapeHtml+
)不 parse,避免每 delta 全量 marked.parse+DOMPurify.sanitize 致主线程阻塞掉帧;不缓存流式文本(每 delta 变,污染缓存);完成后再走 markdown 一次 parse
来源 aichat审查报告 第一章 H1 P0;vue-tsc 0 err
---
src/components/AiChat.vue | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/src/components/AiChat.vue b/src/components/AiChat.vue
index e9f9bd9..b36e121 100644
--- a/src/components/AiChat.vue
+++ b/src/components/AiChat.vue
@@ -197,7 +197,7 @@
class="ai-msg-bubble ai-msg-bubble--ai ai-md"
:class="{ 'ai-msg-bubble--error': msg.isError }"
>
-