chore: upgrade to nuxt v3.2.0 (#1684)

This commit is contained in:
Daniel Roe 2023-02-09 18:47:59 +01:00 committed by GitHub
parent 4400818a31
commit 44c3dd762e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 530 additions and 421 deletions

View file

@ -72,15 +72,6 @@ export default defineNuxtConfig({
}, },
build: { build: {
target: 'esnext', target: 'esnext',
rollupOptions: {
output: {
manualChunks: (id) => {
// TODO: find and resolve issue in nuxt/vite/pwa
if (id.includes('.svg') || id.includes('entry'))
return 'entry'
},
},
},
}, },
}, },
postcss: { postcss: {

View file

@ -38,6 +38,7 @@
"@iconify-json/ri": "^1.1.4", "@iconify-json/ri": "^1.1.4",
"@iconify-json/twemoji": "^1.1.10", "@iconify-json/twemoji": "^1.1.10",
"@iconify/utils": "^2.0.12", "@iconify/utils": "^2.0.12",
"@nuxt/devtools": "^0.1.0",
"@nuxtjs/color-mode": "^3.2.0", "@nuxtjs/color-mode": "^3.2.0",
"@nuxtjs/i18n": "8.0.0-beta.9", "@nuxtjs/i18n": "8.0.0-beta.9",
"@pinia/nuxt": "^0.4.6", "@pinia/nuxt": "^0.4.6",
@ -106,7 +107,6 @@
"devDependencies": { "devDependencies": {
"@antfu/eslint-config": "^0.34.1", "@antfu/eslint-config": "^0.34.1",
"@antfu/ni": "^0.19.0", "@antfu/ni": "^0.19.0",
"@nuxt/devtools": "^0.1.0",
"@types/chroma-js": "^2.1.4", "@types/chroma-js": "^2.1.4",
"@types/file-saver": "^2.0.5", "@types/file-saver": "^2.0.5",
"@types/fnando__sparkline": "^0.3.4", "@types/fnando__sparkline": "^0.3.4",
@ -119,7 +119,7 @@
"esno": "^0.16.3", "esno": "^0.16.3",
"fs-extra": "^11.1.0", "fs-extra": "^11.1.0",
"lint-staged": "^13.1.0", "lint-staged": "^13.1.0",
"nuxt": "3.1.1", "nuxt": "3.2.0",
"prettier": "^2.8.3", "prettier": "^2.8.3",
"simple-git-hooks": "^2.8.1", "simple-git-hooks": "^2.8.1",
"typescript": "^4.9.5", "typescript": "^4.9.5",
@ -149,9 +149,7 @@
"@tiptap/extension-paragraph": "2.0.0-beta.204", "@tiptap/extension-paragraph": "2.0.0-beta.204",
"@tiptap/extension-strike": "2.0.0-beta.204", "@tiptap/extension-strike": "2.0.0-beta.204",
"@tiptap/extension-text": "2.0.0-beta.204", "@tiptap/extension-text": "2.0.0-beta.204",
"vitest>vite": "^3.2.5", "vue": "3.2.45"
"@nuxt/kit": "^3.1.2",
"@nuxt/schema": "^3.1.2"
} }
}, },
"simple-git-hooks": { "simple-git-hooks": {

File diff suppressed because it is too large Load diff

View file

@ -1,10 +1,7 @@
import type { Driver } from 'unstorage' import type { Driver } from 'unstorage'
// @ts-expect-error unstorage needs to provide backwards-compatible subpath types import memory from 'unstorage/drivers/memory'
import _memory from 'unstorage/drivers/memory'
import { defineDriver } from 'unstorage' import { defineDriver } from 'unstorage'
const memory = _memory as typeof import('unstorage/dist/drivers/memory')['default']
export interface CacheDriverOptions { export interface CacheDriverOptions {
driver: Driver driver: Driver
} }

View file

@ -1,7 +1,5 @@
// @ts-expect-error unstorage needs to provide backwards-compatible subpath types import fs from 'unstorage/drivers/fs'
import _fs from 'unstorage/drivers/fs' import memory from 'unstorage/drivers/memory'
// @ts-expect-error unstorage needs to provide backwards-compatible subpath types
import _memory from 'unstorage/drivers/memory'
import { stringifyQuery } from 'ufo' import { stringifyQuery } from 'ufo'
@ -19,9 +17,6 @@ import { driver } from '#storage-config'
import type { AppInfo } from '~/types' import type { AppInfo } from '~/types'
import { APP_NAME } from '~/constants' import { APP_NAME } from '~/constants'
const fs = _fs as typeof import('unstorage/dist/drivers/fs')['default']
const memory = _memory as typeof import('unstorage/dist/drivers/memory')['default']
const storage = useStorage() as Storage const storage = useStorage() as Storage
if (driver === 'fs') { if (driver === 'fs') {