forked from jimafisk/self-hosted
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvite.config.js
More file actions
27 lines (25 loc) · 699 Bytes
/
Copy pathvite.config.js
File metadata and controls
27 lines (25 loc) · 699 Bytes
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
import { sveltekit } from '@sveltejs/kit/vite';
/** @type {import('vite').UserConfig} */
const config = {
plugins: [sveltekit()],
test: {
include: ['src/**/*.{test,spec}.{js,ts}']
},
server: {
fs: {
// throws an error without this when importing Fira font
allow: ['..', 'node_modules/@fontsource/fira-code']
},
proxy: {},
port: 5174,
headers: {
'Access-Control-Allow-Origin': '*',
'Access-Control-Allow-Methods': 'GET,OPTIONS,PATCH,DELETE,POST,PUT',
'Access-Control-Allow-Headers': 'Content-Type, Authorization',
}
},
define: {
'__SERVER_VERSION__': JSON.stringify(process.env.npm_package_version),
}
};
export default config;