diff --git a/packages/repl/repl-component.mjs b/packages/repl/repl-component.mjs index 44220766..a4b14a0d 100644 --- a/packages/repl/repl-component.mjs +++ b/packages/repl/repl-component.mjs @@ -53,7 +53,7 @@ class StrudelRepl extends HTMLElement { attributeChangedCallback(name, oldValue, newValue) { if (name === 'code') { this.code = newValue; - this.editor?.setCode(initialCode); + this.editor?.setCode(newValue); } else if (settingAttributes.includes(name)) { const camel = kebabToCamel(name); this.settings[camel] = parseAttribute(name, newValue); diff --git a/website/src/pages/vanilla/mini.astro b/website/src/pages/vanilla/mini.astro index 68dccb8a..2f8e8599 100644 --- a/website/src/pages/vanilla/mini.astro +++ b/website/src/pages/vanilla/mini.astro @@ -8,7 +8,7 @@ import HeadCommonNew from '../../components/HeadCommonNew.astro';