You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Taylor Hunt edited this page Aug 2, 2019
·
2 revisions
The id for the outermost HTML element of a component must be static. Components are uniquely identified by their id; if that id changes during a re-render, then diffing and patching will break.
Erroneous code
$var id =input.id;
<divid=id/>
Fixed code
$var id =input.id;
<div>
<divid=id/>
</div>
If you don’t care about the exact value of the id, you can also have Marko generate one for you with id:scoped: