From 046145fdd7a0bf245770f7866530ae263b927708 Mon Sep 17 00:00:00 2001 From: Simon H <5968653+dummdidumm@users.noreply.github.com> Date: Mon, 31 Mar 2025 20:41:20 +0200 Subject: [PATCH] fix: make sure CSS is preserved during SSR with bindings (#15645) fixes #15543 No test because this is a one-liner in a stable part of the code-base, also it can only happen within legacy mode when using bindings which is not getting any new updates at this point --- .changeset/smooth-mugs-grin.md | 5 +++++ packages/svelte/src/internal/server/index.js | 1 + 2 files changed, 6 insertions(+) create mode 100644 .changeset/smooth-mugs-grin.md diff --git a/.changeset/smooth-mugs-grin.md b/.changeset/smooth-mugs-grin.md new file mode 100644 index 0000000000..3302a63012 --- /dev/null +++ b/.changeset/smooth-mugs-grin.md @@ -0,0 +1,5 @@ +--- +'svelte': patch +--- + +fix: make sure CSS is preserved during SSR with bindings diff --git a/packages/svelte/src/internal/server/index.js b/packages/svelte/src/internal/server/index.js index 6098b496c5..bf36a595d8 100644 --- a/packages/svelte/src/internal/server/index.js +++ b/packages/svelte/src/internal/server/index.js @@ -49,6 +49,7 @@ export function copy_payload({ out, css, head, uid }) { */ export function assign_payload(p1, p2) { p1.out = p2.out; + p1.css = p2.css; p1.head = p2.head; p1.uid = p2.uid; }