perf(query-core): useQueries have quadratic performance in relation to the number of queries(#8604) #8686
Closedzktm9903(GitHub profile, opens in a new tab)wants to merge 3 commits into
main fromrefs/pull/8686/headopened View on GitHubgithub-actions[bot](GitHub profile, opens in a new tab) added labelspackage: query-core
TkDodo closed this
Sign in to join this conversation.
TkDodo reviewed
I’m not a fan of storing the observers in both a Map and an Array, and the whole thing becomes more complex.
The only reason we have an Array is because users pass in
Array<QueryObserverOptions>, and we need to keep that order. Maybe storing this as aMap<index, QueryObserver>only would work?