I’ve got this custom collection with a button as a checkbox. When I click it, it triggers a query. I would like to get a loading icon with isfetching. But I tried it once and it will set all buttons to. “Is fetching”.
Is there a method to just make the button I pressed change state?
My apologies for the naming of the variable variable2. It’s an array of items. So I look up the item in the array and if it has the same ID as the one I clicked, I set it to true.
I just change the icon. But if the query takes longer than expected, this can take some time. Which makes the button seem unresponsive. That’s why I want to use isfetching.
The issue is that when I use isfetching, it’s applying that for every button in the collectionlist. How do I target only the one that’s clicked/pressed?