We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding config (even empty object) as a third argument to the useSWR hook results in missing undefined in the data type:
useSWR
data
const { data } = useSWR<FetchResult>( "/url", (url) => fetch(url).then((r) => r.json()), {} );
data type is FetchResult but should be FetchResult | undefined
FetchResult
FetchResult | undefined
Could be related to this swr issue
Codesandbox
SWR version. 2.1.0
The text was updated successfully, but these errors were encountered:
Fixed in #2506
Sorry, something went wrong.
No branches or pull requests
Adding config (even empty object) as a third argument to the
useSWR
hook results in missing undefined in thedata
type:data
type isFetchResult
but should beFetchResult | undefined
Could be related to this swr issue
Codesandbox
SWR version.
2.1.0
The text was updated successfully, but these errors were encountered: