chore: add ofetch
to typescript.hoist
(#2693)
Co-authored-by: Daniel Roe <daniel@roe.dev>
This commit is contained in:
parent
bd4cd02b2b
commit
9251ec496b
|
@ -55,15 +55,10 @@ export default defineNuxtPlugin(async () => {
|
||||||
const localCall = createCall(toNodeListener(h3App) as any)
|
const localCall = createCall(toNodeListener(h3App) as any)
|
||||||
const localFetch = createLocalFetch(localCall, globalThis.fetch)
|
const localFetch = createLocalFetch(localCall, globalThis.fetch)
|
||||||
|
|
||||||
// eslint-disable-next-line ts/prefer-ts-expect-error
|
|
||||||
// @ts-ignore error TS2321: Excessive stack depth comparing types
|
|
||||||
globalThis.$fetch = createFetch({
|
globalThis.$fetch = createFetch({
|
||||||
// eslint-disable-next-line ts/prefer-ts-expect-error
|
// @ts-expect-error slight differences in api
|
||||||
// @ts-ignore slight differences in api
|
|
||||||
fetch: localFetch,
|
fetch: localFetch,
|
||||||
Headers,
|
Headers,
|
||||||
// eslint-disable-next-line ts/prefer-ts-expect-error
|
|
||||||
// @ts-ignore error TS2321: Excessive stack depth comparing types
|
|
||||||
defaults: { baseURL: config.app.baseURL },
|
defaults: { baseURL: config.app.baseURL },
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue