fix: upgrade & downupgrade deps

This commit is contained in:
三咲智子 Kevin Deng 2023-01-25 02:52:48 +08:00
parent d7bba4dbc9
commit 7545921385
No known key found for this signature in database
GPG key ID: 69992F2250DFD93E
11 changed files with 991 additions and 798 deletions

View file

@ -56,7 +56,6 @@ export default defineNuxtModule<VitePWANuxtOptions>({
Object.keys(webmanifests!).map(wm => [wm, `manifest-${wm}.webmanifest`]).forEach(([wm, fileName]) => {
bundle[fileName] = {
isAsset: true,
type: 'asset',
name: undefined,
source: generateManifest(wm),

View file

@ -4,6 +4,7 @@ import {
defineLazyEventHandler,
toNodeListener,
} from 'h3'
import type { FetchResponse } from 'ofetch'
import { createFetch } from 'ofetch'
import {
createCall,
@ -64,7 +65,7 @@ export default defineNuxtPlugin(async () => {
const route = useRoute()
if (route.path.startsWith('/api')) {
const result = await $fetch.raw(route.fullPath)
const result = (await ($fetch.raw as any)(route.fullPath)) as FetchResponse<unknown>
if (result.headers.get('location'))
location.href = result.headers.get('location')!
}