Skip to content

fix: ignore a value set again by the host - #32

Merged
Francois-Francois merged 1 commit into
mainfrom
fix/host-value-echo
Oct 9, 2026
Merged

Francois-Francois merged 1 commit into
mainfrom
fix/host-value-echo

Conversation

@Francois-Francois

Copy link
Copy Markdown
Contributor

Found while checking the Ciklik app (Vue 3 host) against main: Vue patches the value property of a custom element on every render of its parent, with the same initial string. Since the store now lives as long as the element, closing the editor applied the initial value again and erased the user's changes.

The element now ignores a string value equal to the last one set by the host; a different value still replaces the content (0.1.x ignored every value after the first one). server/compat.html now sets the value again on every toggle like Vue does, and the "keeps the content" compatibility spec fails without the fix.

Vue sets the value property of a custom element on every render of its
parent. With the store kept per element, the host's initial value was
applied again when the editor was closed, erasing the user's changes.
Only a new string value replaces the content now, 0.1.x ignored every
value after the first one.

The compatibility page sets the value again on every toggle, like Vue.
@Francois-Francois
Francois-Francois merged commit e4a8982 into main Oct 9, 2026
1 check passed
@Francois-Francois
Francois-Francois deleted the fix/host-value-echo branch October 9, 2026 07:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant