Back to Nuxt

NUXT_E3009

docs/errors/e3009.md

4.5.2334 B
Original Source

E3009

useAsyncData() was called without a handler function. The handler is the function that performs the fetch and returns the data, so it cannot be omitted or of another type.

Resolution

ts
const { data } = useAsyncData('users', () => $fetch('/api/users'))

::read-more{to="/docs/api/composables/use-async-data"} ::