Replies: 2 comments
-
There is https://github.com/dai-shi/react-suspense-fetch. To summarize the API: createFetchStore(fetchFunc: async (...args) -> Value): DataStore;
interface DataStore {
prefetch(...args);
get(...args): Result<Value, SuspensionError>;
evict(...args);
} You'd call |
Beta Was this translation helpful? Give feedback.
-
This comment discusses usage with pre-concurrent mode Suspense. Client designUsually, a client holds a cache that caches cacheable requests that is shared by all hooks under the same provider. Hook designIn a data fetching scenario, a client usually exposes 2 kinds of hooks, usually under the name of
|
Beta Was this translation helpful? Give feedback.
-
I'm planning to add a Yew Suspense support to
reqwasm
: ranile/reqwasm#33. What should the exposed API look like? Is there any other libraries (from other ecosystems) to use as inspiration?Beta Was this translation helpful? Give feedback.
All reactions