Components inside <teleport> are getting the wrong index from for loop
<div v-for="(item, index) in collection">
<teleport to="body">
<button @click="action(index)">Click me</button>
</teleport>
</div>
So the index that is being used is always the last item in the loop, am I missing something?
Hello, thank you for taking time filling this issue!
However, we kindly ask you to use our Issue Helper when creating new issues, in order to ensure every issue provides the necessary information for us to investigate. This explains why your issue has been automatically closed by me (your robot friend!).
I hope to see your helper-created issue very soon!
works fine see sfc