UNPKG

5.08 kBJSONView Raw
1{
2 "$schema": "http://json-schema.org/draft-07/schema",
3 "title": "Custom webpack dev server schema for Angular build facade",
4 "description": "Dev server target options",
5 "type": "object",
6 "properties": {
7 "browserTarget": {
8 "type": "string",
9 "description": "A browser builder target to serve in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`.",
10 "pattern": "^[^:\\s]+:[^:\\s]+(:[^\\s]+)?$",
11 "x-deprecated": "Use 'buildTarget' instead."
12 },
13 "buildTarget": {
14 "type": "string",
15 "description": "A build builder target to serve in the format of `project:target[:configuration]`. You can also pass in more than one configuration name as a comma-separated list. Example: `project:target:production,staging`.",
16 "pattern": "^[^:\\s]*:[^:\\s]*(:[^\\s]+)?$"
17 },
18 "port": {
19 "type": "number",
20 "description": "Port to listen on.",
21 "default": 4200
22 },
23 "host": {
24 "type": "string",
25 "description": "Host to listen on.",
26 "default": "localhost"
27 },
28 "proxyConfig": {
29 "type": "string",
30 "description": "Proxy configuration file. For more information, see https://angular.io/guide/build#proxying-to-a-backend-server."
31 },
32 "ssl": {
33 "type": "boolean",
34 "description": "Serve using HTTPS.",
35 "default": false
36 },
37 "sslKey": {
38 "type": "string",
39 "description": "SSL key to use for serving HTTPS."
40 },
41 "sslCert": {
42 "type": "string",
43 "description": "SSL certificate to use for serving HTTPS."
44 },
45 "headers": {
46 "type": "object",
47 "description": "Custom HTTP headers to be added to all responses.",
48 "propertyNames": {
49 "pattern": "^[-_A-Za-z0-9]+$"
50 },
51 "additionalProperties": {
52 "type": "string"
53 }
54 },
55 "open": {
56 "type": "boolean",
57 "description": "Opens the url in default browser.",
58 "default": false,
59 "alias": "o"
60 },
61 "verbose": {
62 "type": "boolean",
63 "description": "Adds more details to output logging."
64 },
65 "liveReload": {
66 "type": "boolean",
67 "description": "Whether to reload the page on change, using live-reload.",
68 "default": true
69 },
70 "publicHost": {
71 "type": "string",
72 "description": "The URL that the browser client (or live-reload client, if enabled) should use to connect to the development server. Use for a complex dev server setup, such as one with reverse proxies. This option has no effect when using the 'application' or other esbuild-based builders."
73 },
74 "allowedHosts": {
75 "type": "array",
76 "description": "List of hosts that are allowed to access the dev server. This option has no effect when using the 'application' or other esbuild-based builders.",
77 "default": [],
78 "items": {
79 "type": "string"
80 }
81 },
82 "servePath": {
83 "type": "string",
84 "description": "The pathname where the application will be served."
85 },
86 "disableHostCheck": {
87 "type": "boolean",
88 "description": "Don't verify connected clients are part of allowed hosts. This option has no effect when using the 'application' or other esbuild-based builders.",
89 "default": false
90 },
91 "hmr": {
92 "type": "boolean",
93 "description": "Enable hot module replacement.",
94 "default": false
95 },
96 "watch": {
97 "type": "boolean",
98 "description": "Rebuild on change.",
99 "default": true
100 },
101 "poll": {
102 "type": "number",
103 "description": "Enable and define the file watching poll time period in milliseconds."
104 },
105 "forceEsbuild": {
106 "type": "boolean",
107 "description": "Force the development server to use the 'browser-esbuild' builder when building. This is a developer preview option for the esbuild-based build system.",
108 "default": false
109 },
110 "prebundle": {
111 "description": "Enable and control the Vite-based development server's prebundling capabilities. To enable prebundling, the Angular CLI cache must also be enabled. This option has no effect when using the 'browser' or other Webpack-based builders.",
112 "oneOf": [
113 {
114 "type": "boolean"
115 },
116 {
117 "type": "object",
118 "properties": {
119 "exclude": {
120 "description": "List of package imports that should not be prebundled by the development server. The packages will be bundled into the application code itself.",
121 "type": "array",
122 "items": {
123 "type": "string"
124 }
125 }
126 },
127 "additionalProperties": false,
128 "required": [
129 "exclude"
130 ]
131 }
132 ]
133 }
134 },
135 "additionalProperties": false,
136 "anyOf": [
137 {
138 "required": [
139 "buildTarget"
140 ]
141 },
142 {
143 "required": [
144 "browserTarget"
145 ]
146 }
147 ],
148 "$id": "CustomWebpackDevServerSchema"
149}
\No newline at end of file