swr icon indicating copy to clipboard operation
swr copied to clipboard

React Hooks for Data Fetching

Results 188 swr issues
Sort by recently updated
recently updated
newest added

Some restrictions can be applied to swr when suspense is enanbled: * `key` can’t be falsy * `fetcher` can’t be null * `data` can’t be undefined _Note: this is tricky...

area: typing

# Bug report ## Description / Observed Behavior I would like to cancel the fetcher function before it is executed, and return undefined to `useSwr` so that I can use...

discussion
area: suspense

The Cache has been exposed since [1], which supposedly includes a .clear() method [2], which in turn is not actually present in the type definition [3]. This adds it to...

# Bug report ## Description / Observed Behavior If using mutate without parameters, mutate() always return data even if network has been shut down, the error can not be catch....

discussion
improvement

This pr is trying to explore a possible solution for #1041 and #1988 # Motivation In most of time, if users want to render a list of useSWR hooks, they...

Side note: I am writing this with my jaw on the floor. What a clean API. Nice work guys. 😍 This issue refers to the idea of waterfalls as mentioned...

feature request

# Bug report ## Description / Observed Behavior I want to achieve the same effect on the web. But my method of getting localstorage is asynchronous. How can I achieve...

Hi! In my opinion, it's a good practice **not to use default exports**. In that case, I wondered if it would be a good idea to add a separated export...

## CONTEXT Continuing the discussion from #1973 Currently `useSWRMutation` returns a `trigger` method which returns `Promise` which may cause confusion like [here](https://github.com/vercel/swr/discussions/1919#discussioncomment-2688176). though it should be clear to developers if...

discussion
area: mutation

# Bug report ## Description / Observed Behavior I have created a simple component that fetches a list of posts via GraphQL requests (cursor-based) using useSWRInfinite. Apparently everything works fine,...

documentation
area: infinite