Update to sveltekit 1.0
This commit is contained in:
parent
03914855da
commit
4df0eb499e
1552
package-lock.json
generated
1552
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
17
package.json
17
package.json
@ -4,16 +4,19 @@
|
||||
"scripts": {
|
||||
"dev": "vite dev",
|
||||
"build": "vite build",
|
||||
"preview": "vite preview"
|
||||
"preview": "vite preview",
|
||||
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
|
||||
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@sveltejs/adapter-static": "^1.0.0-next.39",
|
||||
"@sveltejs/kit": "next",
|
||||
"svelte": "^3.46.0",
|
||||
"@sveltejs/adapter-static": "^1.0.0",
|
||||
"@sveltejs/kit": "^1.0.0",
|
||||
"svelte": "^3.54.0",
|
||||
"svelte-check": "^2.9.2",
|
||||
"svelte-preprocess": "^4.10.6",
|
||||
"tslib": "^2.3.1",
|
||||
"typescript": "^4.6.4",
|
||||
"vite": "^3.0.9"
|
||||
"tslib": "^2.4.1",
|
||||
"typescript": "^4.9.3",
|
||||
"vite": "^4.0.0"
|
||||
},
|
||||
"type": "module"
|
||||
}
|
||||
|
9
src/app.d.ts
vendored
Normal file
9
src/app.d.ts
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
// See https://kit.svelte.dev/docs/types#app
|
||||
// for information about these interfaces
|
||||
// and what to do when importing types
|
||||
declare namespace App {
|
||||
// interface Error {}
|
||||
// interface Locals {}
|
||||
// interface PageData {}
|
||||
// interface Platform {}
|
||||
}
|
@ -8,12 +8,11 @@
|
||||
|
||||
<link rel="stylesheet" href="/css/bootstrap.min.css">
|
||||
<link rel="stylesheet" href="/css/global.css">
|
||||
<!-- <link rel="manifest" href="manifest.json" crossorigin="use-credentials"> -->
|
||||
<link rel="icon" type="image/png" href="/img/favicon.ico">
|
||||
|
||||
%sveltekit.head%
|
||||
</head>
|
||||
<body>
|
||||
<body data-sveltekit-preload-data="hover">
|
||||
<div id="svelte">%sveltekit.body%</div>
|
||||
</body>
|
||||
</html>
|
||||
|
1
src/routes/+layout.js
Normal file
1
src/routes/+layout.js
Normal file
@ -0,0 +1 @@
|
||||
export const prerender = true;
|
@ -1,5 +1,5 @@
|
||||
<script>
|
||||
import Banner from '../components/Banner.svelte'
|
||||
import Banner from '../../components/Banner.svelte'
|
||||
</script>
|
||||
|
||||
<svelte:head>
|
@ -1,15 +1,21 @@
|
||||
import adapter from "@sveltejs/adapter-static";
|
||||
import preprocess from 'svelte-preprocess';
|
||||
import { vitePreprocess } from '@sveltejs/kit/vite';
|
||||
|
||||
/** @type {import('@sveltejs/kit').Config} */
|
||||
const config = {
|
||||
preprocess: preprocess(),
|
||||
// preprocess: preprocess(),
|
||||
// Consult https://kit.svelte.dev/docs/integrations#preprocessors
|
||||
// for more information about preprocessors
|
||||
preprocess: vitePreprocess(),
|
||||
|
||||
kit: {
|
||||
prerender: {
|
||||
default: true
|
||||
},
|
||||
adapter: adapter({
|
||||
pages: 'build'
|
||||
pages: 'build',
|
||||
assets: 'build',
|
||||
fallback: null,
|
||||
precompress: false,
|
||||
strict: true
|
||||
})
|
||||
}
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user