Closed v1ack closed 3 years ago
Thanks for the code.
Currently I don't think I will merge this since reusing the items an alternative.
I don't want to introduce a bunch of async functions only for this.
The creatable
support in the whole component is shaky, I might rewrite it at some point.
Fixes #102
onCreate
with store doesn't work because we useitems
before it's updated withonCreate
You used a hack with
unshift
in your examplecolors
stays the same object (same link), but it doesn't work with store or svelte-way reactive array update (likecolors = [newColor, ...colors]
)So, we need to wait for reactive
items
update before finding created item