forked from eduardolat/kokoro-web
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsvelte.config.js
More file actions
executable file
路48 lines (39 loc) 路 1.44 KB
/
Copy pathsvelte.config.js
File metadata and controls
executable file
路48 lines (39 loc) 路 1.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
import { vitePreprocess } from "@sveltejs/vite-plugin-svelte";
import adapterNetlify from "@sveltejs/adapter-netlify"; // Import the netlify adapter
// The following lines for adapterNode and adapterStatic are commented out
// as we are now defaulting to adapter-netlify.
// import adapterNode from "@sveltejs/adapter-node";
// import adapterStatic from "@sveltejs/adapter-static";
// // https://svelte.dev/docs/kit/adapter-node
// let adapter = adapterNode();
// // https://svelte.dev/docs/kit/adapter-static
// if (process.env.ADAPTER === "static") {
// adapter = adapterStatic({
// strict: false,
// fallback: "index.html",
// });
// }
// Use adapterNetlify by default
let adapter = adapterNetlify({
// Netlify Edge Functions are enabled by default
// edge: true,
// To disable Edge Functions and use regular Netlify Functions:
// edge: false,
// split: false, // if you don't want to split functions
});
/** @type {import('@sveltejs/kit').Config} */
const config = {
// Consult https://svelte.dev/docs/kit/integrations
// for more information about preprocessors
preprocess: vitePreprocess(),
kit: {
// See https://svelte.dev/docs/kit/adapters for more information about adapters.
adapter: adapter, // This will now use adapterNetlify by default
// See https://svelte.dev/docs/kit/configuration#env
env: {
privatePrefix: "KW_SECRET_",
publicPrefix: "KW_PUBLIC_",
},
},
};
export default config;