giray
giray8mo ago

Is Client library acts like a store?

Hey, I have simple question. Does convex eliminates the need to use any global state libray? If I subscribe to the same exact query from different components, does it fetch multiple times or only once? Sorry the caching section in the docs, I guess, only relates to the backend caching.
2 Replies
lee
lee8mo ago
if you subscribe to the same exact query from different components underneath one <ConvexProvider>, it will fetch once
erquhart
erquhart8mo ago
No need for tanstack query, swr, etc. One of my favorite aspects of using Convex.