Upgrade SvelteKit
This commit is contained in:
parent
4d12eab0c3
commit
84eec84be5
6 changed files with 966 additions and 567 deletions
|
@ -7,18 +7,24 @@ module.exports = {
|
||||||
extends: [
|
extends: [
|
||||||
"eslint:recommended",
|
"eslint:recommended",
|
||||||
"plugin:@typescript-eslint/recommended",
|
"plugin:@typescript-eslint/recommended",
|
||||||
|
"plugin:svelte/recommended",
|
||||||
"prettier",
|
"prettier",
|
||||||
],
|
],
|
||||||
ignorePatterns: ["*.cjs"],
|
overrides: [
|
||||||
overrides: [{ files: ["*.svelte"], processor: "svelte3/svelte3" }],
|
{
|
||||||
|
files: ["*.svelte"],
|
||||||
|
parser: "svelte-eslint-parser",
|
||||||
|
parserOptions: {
|
||||||
|
parser: "@typescript-eslint/parser",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
parser: "@typescript-eslint/parser",
|
parser: "@typescript-eslint/parser",
|
||||||
parserOptions: {
|
parserOptions: {
|
||||||
sourceType: "module",
|
|
||||||
ecmaVersion: 2020,
|
ecmaVersion: 2020,
|
||||||
|
extraFileExtensions: [".svelte"],
|
||||||
|
sourceType: "module",
|
||||||
},
|
},
|
||||||
plugins: ["svelte3", "@typescript-eslint"],
|
plugins: ["@typescript-eslint"],
|
||||||
root: true,
|
root: true,
|
||||||
settings: {
|
|
||||||
"svelte3/typescript": () => require("typescript"),
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
1
.npmrc
1
.npmrc
|
@ -1 +1,2 @@
|
||||||
engine-strict=true
|
engine-strict=true
|
||||||
|
resolution-mode=highest
|
||||||
|
|
1483
package-lock.json
generated
1483
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -64,7 +64,7 @@
|
||||||
"dotenv": "^16.0.1",
|
"dotenv": "^16.0.1",
|
||||||
"eslint": "^8.16.0",
|
"eslint": "^8.16.0",
|
||||||
"eslint-config-prettier": "^8.3.0",
|
"eslint-config-prettier": "^8.3.0",
|
||||||
"eslint-plugin-svelte3": "^4.0.0",
|
"eslint-plugin-svelte": "^2.28.0",
|
||||||
"fast-xml-parser": "^4.0.9",
|
"fast-xml-parser": "^4.0.9",
|
||||||
"fs-extra": "^11.1.0",
|
"fs-extra": "^11.1.0",
|
||||||
"he": "^1.2.0",
|
"he": "^1.2.0",
|
||||||
|
@ -77,7 +77,7 @@
|
||||||
"postgres": "^3.2.4",
|
"postgres": "^3.2.4",
|
||||||
"prettier": "^2.6.2",
|
"prettier": "^2.6.2",
|
||||||
"prettier-plugin-svelte": "^2.7.0",
|
"prettier-plugin-svelte": "^2.7.0",
|
||||||
"prettier-plugin-tailwindcss": "^0.2.2",
|
"prettier-plugin-tailwindcss": "^0.3.0",
|
||||||
"sade": "^1.8.1",
|
"sade": "^1.8.1",
|
||||||
"svelte-check": "^3.0.3",
|
"svelte-check": "^3.0.3",
|
||||||
"svelte2tsx": "^0.6.0",
|
"svelte2tsx": "^0.6.0",
|
||||||
|
@ -89,7 +89,7 @@
|
||||||
"zx": "^7.1.1"
|
"zx": "^7.1.1"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@sveltejs/kit": "^1.15.5",
|
"@sveltejs/kit": "^1.18.0",
|
||||||
"svelte": "^3.56.0"
|
"svelte": "^3.56.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
7
src/app.d.ts
vendored
7
src/app.d.ts
vendored
|
@ -1,9 +1,12 @@
|
||||||
// See https://kit.svelte.dev/docs/types#app
|
// See https://kit.svelte.dev/docs/types#app
|
||||||
// for information about these interfaces
|
// for information about these interfaces
|
||||||
// and what to do when importing types
|
declare global {
|
||||||
declare namespace App {
|
namespace App {
|
||||||
// interface Error {}
|
// interface Error {}
|
||||||
// interface Locals {}
|
// interface Locals {}
|
||||||
// interface PageData {}
|
// interface PageData {}
|
||||||
// interface Platform {}
|
// interface Platform {}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export {}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import { sveltekit } from "@sveltejs/kit/vite"
|
import { sveltekit } from "@sveltejs/kit/vite"
|
||||||
import morgan from "morgan"
|
import morgan from "morgan"
|
||||||
import type { UserConfig } from "vite"
|
import { defineConfig } from "vite"
|
||||||
|
|
||||||
const middlewaresPlugin = {
|
const middlewaresPlugin = {
|
||||||
name: "tricoteuses-middlewares",
|
name: "tricoteuses-middlewares",
|
||||||
|
@ -9,8 +9,6 @@ const middlewaresPlugin = {
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
const config: UserConfig = {
|
export default defineConfig({
|
||||||
plugins: [sveltekit(), middlewaresPlugin],
|
plugins: [sveltekit(), middlewaresPlugin],
|
||||||
}
|
})
|
||||||
|
|
||||||
export default config
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue