From b125d6c05e3e191f0934b98d29a0e20583ca2224 Mon Sep 17 00:00:00 2001 From: Hatem Hosny Date: Fri, 13 Dec 2024 21:07:51 +0200 Subject: [PATCH] fix(website): update code samples to Svelte 5 --- website/src/helpers/get-framework-code.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/website/src/helpers/get-framework-code.ts b/website/src/helpers/get-framework-code.ts index 86b96e8..6236174 100644 --- a/website/src/helpers/get-framework-code.ts +++ b/website/src/helpers/get-framework-code.ts @@ -27,6 +27,9 @@ export const getFrameworkCode = ( if (lang === 'ts') { return `\nconst options: Options = ${stringify(codeOptions)};`; } + if (lang === 'svelte') { + return `\let options = $state(${stringify(codeOptions)});`; + } return `\nconst options = ${stringify(codeOptions)};`; };