-
Notifications
You must be signed in to change notification settings - Fork 24
/
svelte.config.js
47 lines (40 loc) · 1.02 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
/**
* SvelteKit configuration file. See:
* https://kit.svelte.dev/docs/configuration
*/
import node from '@sveltejs/adapter-node';
import { sveltePreprocess } from 'svelte-preprocess';
import postcssConfig from './postcss.config.js';
/** @type {import('@sveltejs/kit').Config} */
const config = {
kit: {
adapter: node({
envPrefix: 'FRONTEND_'
}),
alias: {
'design-system-fonts': 'deps/fonts',
'trade-executor': 'src/lib/trade-executor',
wizard: 'src/routes/wizard'
},
// prevent clickjacking (block 3rd-parties from including site via iframe)
csp: {
directives: {
'frame-ancestors': ['self']
}
},
// disable CSRF origin checking for now; see:
// - https://kit.svelte.dev/docs/configuration#csrf
// - https://github.com/sveltejs/kit/tree/master/packages/adapter-node#origin-protocol_header-and-host_header
csrf: {
checkOrigin: false
},
env: {
publicPrefix: 'TS_PUBLIC_'
}
},
preprocess: sveltePreprocess({
sourceMap: true,
postcss: postcssConfig
})
};
export default config;