-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsvelte.config.js
63 lines (61 loc) · 2.22 KB
/
svelte.config.js
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
// import adapterAuto from '@sveltejs/adapter-auto'
import adapterNode from '@sveltejs/adapter-node'
import { vitePreprocess } from '@sveltejs/kit/vite'
import { preprocessMeltUI } from '@melt-ui/pp'
import sequence from 'svelte-sequential-preprocessor'
/** @type {import('@sveltejs/kit').Config} */
const config = {
kit: {
// adapter-auto only supports some environments, see https://kit.svelte.dev/docs/adapter-auto for a list.
// If your environment is not supported or you settled on a specific environment, switch out the adapter.
// See https://kit.svelte.dev/docs/adapters for more information about adapters.
// adapter: process.env.NODE_ENV === 'development'
// ? adapterAuto()
// : adapterNode(),
adapter: adapterNode(),
csrf: {
// csrf.check_origin fails in dev mode
// https://github.com/sveltejs/kit/issues/8026
// checkOrigin: process.env.NODE_ENV === 'development' ? false : true
checkOrigin: false
},
csp: {
directives: {
"default-src": [
'self'
],
"connect-src": [
'self',
'data:',
'ws:',
'wss:',
'https://apis.google.com/',
'https://accounts.google.com/gsi/',
'https://filetools2.pdf24.org/'
],
"frame-src": [
'self',
'https://accounts.google.com/gsi/',
],
"script-src": [
'self',
'unsafe-eval',
'https://accounts.google.com/gsi/client',
'https://apis.google.com'
],
"style-src": [
'self',
'unsafe-inline',
'https://accounts.google.com/gsi/style',
],
"img-src": [
'self',
'data:',
'https://lh3.googleusercontent.com'
]
}
}
},
preprocess: sequence([vitePreprocess(), preprocessMeltUI()]),
};
export default config;