I want to specify the APIBody type as follows, but it results in an error: Property ‘test’ does not exist on type ‘NonNullable<PickFrom<_ResT, KeysOf>>’. Is there currently no way to specify the return type of useFetch? If so, it feels very inconvenient…
type APIBody = {
test: string
}
const {data, error} = await useFetch<APIBody>("api_url here")
console.log(data.test) // Property 'test' does not exist on type 'NonNullable<PickFrom<_ResT, KeysOf<DataT>>>'.