DEV Community

Discussion on: Drag and drop with Svelte using svelte-dnd-action

Collapse
 
ivan_jrmc profile image
Ivan Jeremic • Edited

Sure here a codesanbox with the example. I need to say that I'm new at Svelte coming from React so I'm sure I'm missing something would be awesome if you could take a look, thanks! codesandbox.io/s/svelte-api-dnd-9wzpe PS. the codesanbox is a bit buggy you need to refresh it in order to show the app.

Thread Thread
 
isaachagoel profile image
Isaac Hagoel

line 30 should be {#each items as todo(todo.id)}
you are iterating over a variable you are not updating in handleSort

Thread Thread
 
ivan_jrmc profile image
Ivan Jeremic

thanks