From 122ecb5769e20173c99033ade0057d38e12cb384 Mon Sep 17 00:00:00 2001
From: Owen Jacobson <owen@grimoire.ca>
Date: Fri, 15 Nov 2024 01:18:41 -0500
Subject: HTML-ify message bodies once, on receipt, and not every time the
 message is rendered.

~16% of the `hi development` channel's rendering time was taken up on this.
---
 ui/lib/components/MessageRun.svelte | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'ui/lib/components/MessageRun.svelte')

diff --git a/ui/lib/components/MessageRun.svelte b/ui/lib/components/MessageRun.svelte
index 83a82a9..39ee155 100644
--- a/ui/lib/components/MessageRun.svelte
+++ b/ui/lib/components/MessageRun.svelte
@@ -16,7 +16,7 @@
   <span class="chip variant-soft sticky top-o left-0">
     @{name}:
   </span>
-  {#each messages as { id, at, body }}
-    <Message {id} {at} {body} editable={ownMessage} />
+  {#each messages as { id, at, body, renderedBody }}
+    <Message {id} {at} {body} {renderedBody} editable={ownMessage} />
   {/each}
 </div>
-- 
cgit v1.2.3

