NuxtN
Nuxt3y ago
Flinty

useLazyFetch error Nuxt 3.4

Hey!

let {data:data, pending:pending, refresh:refresh, error:error} = await useLazyFetch(url, {headers:headers})
console.log("ERROR API", error)

I get the following console log when a GET request is made (with the code above), however the error object returned by the lazyFetch is not useful (see image):

This was working fine when I was on rc14
My headers and URL is correct to the best of my knowledge
When I change from useLazyFetch to useFetch it works. But I don't want to block navigation till after the API calls. Any ideas?
image.png
Was this page helpful?