-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathweb-dev-server.config.js
59 lines (42 loc) · 1.54 KB
/
web-dev-server.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
/*
https://modern-web.dev/docs/dev-server/cli-and-configuration/
*/
export default {
// whether to open the browser and/or the browser path to open on
open: true,
// index HTML to use for SPA routing / history API fallback
appIndex: '/index.html',
// run in watch mode, reloading when files change
watch: true,
// resolve bare module imports
nodeResolve: false,
// JS language target to compile down to using esbuild. Recommended value is "auto", which compiles based on user agent.
// esbuildTarget: 'auto',
// preserve symlinks when resolve imports, instead of following symlinks to their original files
// preserveSymlinks: boolean,
// the root directory to serve files from. this is useful in a monorepo
// when executing commands from a package
rootDir: './src',
// prefix to strip from request urls
// basePath: string,
/**
* Whether to log debug messages.
*/
// debug: boolean,
// files to serve with a different mime type
// mimeTypes: MimeTypeMappings,
// middleware used by the server to modify requests/responses, for example to proxy requests or rewrite urls
// middleware: Middleware[],
// plugins used by the server to serve or transform files
// plugins: Plugin[],
// configuration for the server
protocol: 'https',
// hostname?: string,
port: 9009,
// whether to run the server with HTTP2
http2: true,
// path to SSL key
// sslKey: string,
// path to SSL certificate
// sslCert: string,
};