Stackable List - Ordering items

Hey guys!
I’m having difficulty using the Stackable List element. I want to list a list of items from a collection (this collection has the “index” field) and update the position of the moved item and the other affected items in the order so that there is no repeated “index” field in the collection.
How to configure the action?

image

Thanks for your help!

How are you keeping the track of the index within the db?

This way here:
With an int8 field in Supabase that receives an integer value

You would need to use the change variable value and the stack events to change the indexes accordingly and update the list. You can use remove at index and insert at index, and partial updates to achieve this.