rgommezz/react-native-offline
The issue has been solved
Option to pass in a custom comparison function to detect similar thunks in queue #206
LiquidSean posted onGitHub
I am curious on thoughts of having a custom comparison function for thunks being added to queue. To elaborate further I would like to have more control over actions being added to the queue. What could help is being able to define a comparison function for actions that will be added to the queue. So when these actions are added a comparison function would be run to determine if a match exists. If a match exists replace current queued action with new one. This comparison is on the thunks actual parameters so IDs or other parameters. This would ensure uniqueness for items added. Thoughts on this would be appreciated.