useFetch
data return null with mismatching client/request options #13583
Closed
Description
Environment
------------------------------
- Operating System: `Linux`
- Node Version: `v16.14.2`
- Nuxt Version: `3.0.0-27480123.4c77c88`
- Package Manager: `yarn@1.22.18`
- Builder: `vite`
- User Config: `-`
- Runtime Modules: `-`
- Build Modules: `-`
------------------------------
Reproduction
In clean Nuxt project:
<template>
<div>
<NuxtWelcome />
</div>
</template>
<script lang="ts" setup>
const [{ data: organization }, { data: repos }] = await Promise.all([
useFetch(`https://api.github.com/orgs/nuxt`),
useFetch(`https://api.github.com/orgs/nuxt/repos`)
])
console.log(organization.value) // null
const { data: organization } = await useFetch(`https://api.github.com/orgs/nuxt`)
console.log(organization.value) // null
</script>
Describe the bug
useFetch started returning null to the "data" property
Additional context
No response
Logs
No response
Activity