webpack-dev-server 3.11.3 → 4.0.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +596 -0
- package/README.md +87 -12
- package/bin/cli-flags.js +338 -112
- package/bin/webpack-dev-server.js +135 -144
- package/client/clients/BaseClient.js +2 -4
- package/client/clients/SockJSClient.js +13 -13
- package/client/clients/WebsocketClient.js +10 -13
- package/client/index.js +106 -58
- package/client/modules/logger/SyncBailHookFake.js +10 -0
- package/client/modules/logger/index.js +3463 -0
- package/client/modules/sockjs-client/index.js +6633 -0
- package/client/modules/strip-ansi/index.js +87 -0
- package/client/overlay.js +5 -4
- package/client/socket.js +5 -10
- package/client/utils/createSocketURL.js +81 -0
- package/client/utils/getCurrentScriptSource.js +7 -4
- package/client/utils/log.js +9 -38
- package/client/utils/parseURL.js +43 -0
- package/client/utils/reloadApp.js +2 -3
- package/client/utils/sendMessage.js +1 -1
- package/client/webpack.config.js +57 -0
- package/lib/Server.js +425 -403
- package/lib/options.json +370 -334
- package/lib/servers/SockJSServer.js +14 -8
- package/lib/servers/WebsocketServer.js +5 -4
- package/lib/utils/DevServerPlugin.js +218 -0
- package/lib/utils/createDomain.js +13 -11
- package/lib/utils/findPort.js +3 -10
- package/lib/utils/getCertificate.js +7 -2
- package/lib/utils/getColorsOption.js +15 -0
- package/lib/utils/getCompilerConfigArray.js +8 -0
- package/lib/utils/getSocketClientPath.d.ts +3 -0
- package/lib/utils/getSocketClientPath.js +1 -0
- package/lib/utils/getSocketServerImplementation.js +1 -1
- package/lib/utils/getStatsOption.js +16 -0
- package/lib/utils/normalizeOptions.js +96 -15
- package/lib/utils/routes.js +34 -62
- package/lib/utils/runBonjour.js +4 -3
- package/lib/utils/runOpen.js +67 -21
- package/lib/utils/setupExitSignals.js +15 -11
- package/package.json +65 -70
- package/bin/options.js +0 -187
- package/client/index.bundle.js +0 -1
- package/client/live.bundle.js +0 -25
- package/client/live.html +0 -1
- package/client/sockjs.bundle.js +0 -1
- package/client/utils/createSocketUrl.js +0 -88
- package/lib/utils/addEntries.js +0 -160
- package/lib/utils/createConfig.js +0 -233
- package/lib/utils/createLogger.js +0 -23
- package/lib/utils/defaultPort.js +0 -3
- package/lib/utils/defaultTo.js +0 -7
- package/lib/utils/getVersions.js +0 -10
- package/lib/utils/processOptions.js +0 -44
- package/lib/utils/status.js +0 -61
- package/lib/utils/tryParseInt.js +0 -13
- package/lib/utils/updateCompiler.js +0 -73
- package/ssl/.gitkeep +0 -0
package/lib/options.json
CHANGED
|
@@ -1,117 +1,264 @@
|
|
|
1
1
|
{
|
|
2
2
|
"type": "object",
|
|
3
|
-
"
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
3
|
+
"definitions": {
|
|
4
|
+
"StaticObject": {
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"properties": {
|
|
8
|
+
"directory": {
|
|
9
|
+
"type": "string",
|
|
10
|
+
"minLength": 1,
|
|
11
|
+
"description": "Directory for static contents."
|
|
12
|
+
},
|
|
13
|
+
"staticOptions": {
|
|
14
|
+
"type": "object",
|
|
15
|
+
"additionalProperties": true
|
|
16
|
+
},
|
|
17
|
+
"publicPath": {
|
|
18
|
+
"anyOf": [
|
|
19
|
+
{
|
|
20
|
+
"type": "string",
|
|
21
|
+
"minLength": 1
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"type": "array",
|
|
25
|
+
"items": {
|
|
26
|
+
"type": "string",
|
|
27
|
+
"minLength": 1
|
|
28
|
+
},
|
|
29
|
+
"minItems": 1
|
|
30
|
+
}
|
|
31
|
+
],
|
|
32
|
+
"description": "The bundled files will be available in the browser under this path."
|
|
33
|
+
},
|
|
34
|
+
"serveIndex": {
|
|
35
|
+
"anyOf": [
|
|
36
|
+
{
|
|
37
|
+
"type": "boolean"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"type": "object",
|
|
41
|
+
"additionalProperties": true
|
|
42
|
+
}
|
|
43
|
+
],
|
|
44
|
+
"description": "Tells dev-server to use serveIndex middleware when enabled."
|
|
45
|
+
},
|
|
46
|
+
"watch": {
|
|
47
|
+
"anyOf": [
|
|
48
|
+
{
|
|
49
|
+
"type": "boolean"
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
"type": "object",
|
|
53
|
+
"description": "options for watch, description available at https://github.com/paulmillr/chokidar#api"
|
|
54
|
+
}
|
|
55
|
+
],
|
|
56
|
+
"description": "Watch for files in static content directory."
|
|
57
|
+
}
|
|
11
58
|
}
|
|
12
59
|
},
|
|
13
|
-
"
|
|
14
|
-
"
|
|
60
|
+
"StaticString": {
|
|
61
|
+
"type": "string",
|
|
62
|
+
"minLength": 1
|
|
15
63
|
},
|
|
16
|
-
"
|
|
64
|
+
"OpenBoolean": {
|
|
17
65
|
"type": "boolean"
|
|
18
66
|
},
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
|
|
22
|
-
|
|
67
|
+
"OpenString": {
|
|
68
|
+
"type": "string",
|
|
69
|
+
"minLength": 1
|
|
70
|
+
},
|
|
71
|
+
"OpenObject": {
|
|
72
|
+
"type": "object",
|
|
73
|
+
"additionalProperties": false,
|
|
74
|
+
"properties": {
|
|
75
|
+
"target": {
|
|
76
|
+
"anyOf": [
|
|
77
|
+
{
|
|
78
|
+
"type": "boolean"
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"type": "string",
|
|
82
|
+
"minLength": 1
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
"type": "array",
|
|
86
|
+
"items": {
|
|
87
|
+
"type": "string",
|
|
88
|
+
"minLength": 1
|
|
89
|
+
},
|
|
90
|
+
"minItems": 1
|
|
91
|
+
}
|
|
92
|
+
],
|
|
93
|
+
"description": "Open specified route in browser."
|
|
23
94
|
},
|
|
24
|
-
{
|
|
25
|
-
"
|
|
95
|
+
"app": {
|
|
96
|
+
"anyOf": [
|
|
97
|
+
{
|
|
98
|
+
"type": "string",
|
|
99
|
+
"minLength": 1
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"type": "array",
|
|
103
|
+
"items": {
|
|
104
|
+
"type": "string",
|
|
105
|
+
"minLength": 1
|
|
106
|
+
},
|
|
107
|
+
"minItems": 1
|
|
108
|
+
}
|
|
109
|
+
],
|
|
110
|
+
"description": "Open specified browser."
|
|
26
111
|
}
|
|
27
|
-
|
|
112
|
+
}
|
|
28
113
|
},
|
|
29
|
-
"
|
|
30
|
-
"
|
|
31
|
-
|
|
32
|
-
|
|
114
|
+
"WatchFilesString": {
|
|
115
|
+
"type": "string",
|
|
116
|
+
"minLength": 1
|
|
117
|
+
},
|
|
118
|
+
"WatchFilesObject": {
|
|
119
|
+
"type": "object",
|
|
120
|
+
"properties": {
|
|
121
|
+
"paths": {
|
|
122
|
+
"anyOf": [
|
|
123
|
+
{
|
|
124
|
+
"type": "string",
|
|
125
|
+
"minLength": 1
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
"type": "array",
|
|
129
|
+
"items": {
|
|
130
|
+
"type": "string",
|
|
131
|
+
"minLength": 1
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
]
|
|
33
135
|
},
|
|
34
|
-
{
|
|
35
|
-
"
|
|
136
|
+
"options": {
|
|
137
|
+
"type": "object",
|
|
138
|
+
"additionalProperties": true
|
|
36
139
|
}
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
"error",
|
|
44
|
-
"debug",
|
|
45
|
-
"trace",
|
|
46
|
-
"silent",
|
|
47
|
-
"none",
|
|
48
|
-
"warning"
|
|
49
|
-
]
|
|
50
|
-
},
|
|
51
|
-
"compress": {
|
|
52
|
-
"type": "boolean"
|
|
53
|
-
},
|
|
54
|
-
"contentBasePublicPath": {
|
|
140
|
+
},
|
|
141
|
+
"additionalProperties": false
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
"properties": {
|
|
145
|
+
"bonjour": {
|
|
55
146
|
"anyOf": [
|
|
56
147
|
{
|
|
57
|
-
"type": "
|
|
148
|
+
"type": "boolean"
|
|
58
149
|
},
|
|
59
150
|
{
|
|
60
|
-
"type": "
|
|
61
|
-
"items": {
|
|
62
|
-
"type": "string"
|
|
63
|
-
},
|
|
64
|
-
"minItems": 1
|
|
151
|
+
"type": "object"
|
|
65
152
|
}
|
|
66
|
-
]
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
153
|
+
],
|
|
154
|
+
"description": "Broadcasts the server via ZeroConf networking on start. https://webpack.js.org/configuration/dev-server/#devserverbonjour"
|
|
155
|
+
},
|
|
156
|
+
"client": {
|
|
157
|
+
"type": "object",
|
|
158
|
+
"properties": {
|
|
159
|
+
"host": {
|
|
160
|
+
"type": "string",
|
|
161
|
+
"description": "Tells clients connected to devServer to use the provided host."
|
|
72
162
|
},
|
|
73
|
-
{
|
|
74
|
-
"type": "
|
|
163
|
+
"path": {
|
|
164
|
+
"type": "string",
|
|
165
|
+
"description": "Tells clients connected to devServer to use the provided port."
|
|
75
166
|
},
|
|
76
|
-
{
|
|
77
|
-
"
|
|
167
|
+
"port": {
|
|
168
|
+
"anyOf": [
|
|
169
|
+
{
|
|
170
|
+
"type": "number"
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
"type": "string"
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
"type": "null"
|
|
177
|
+
}
|
|
178
|
+
],
|
|
179
|
+
"description": "Tells clients connected to devServer to use the provided path to connect."
|
|
78
180
|
},
|
|
79
|
-
{
|
|
80
|
-
"
|
|
81
|
-
"
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
"
|
|
181
|
+
"logging": {
|
|
182
|
+
"enum": ["none", "error", "warn", "info", "log", "verbose"],
|
|
183
|
+
"decription": "Log level in the browser."
|
|
184
|
+
},
|
|
185
|
+
"progress": {
|
|
186
|
+
"type": "boolean",
|
|
187
|
+
"description": "Print compilation progress in percentage in the browser."
|
|
188
|
+
},
|
|
189
|
+
"overlay": {
|
|
190
|
+
"anyOf": [
|
|
191
|
+
{
|
|
192
|
+
"type": "boolean",
|
|
193
|
+
"description": "Show a full-screen overlay in the browser when there are compiler errors or warnings."
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
"type": "object",
|
|
197
|
+
"properties": {
|
|
198
|
+
"errors": {
|
|
199
|
+
"type": "boolean",
|
|
200
|
+
"description": "Show a full-screen overlay in the browser when there are compiler errors."
|
|
201
|
+
},
|
|
202
|
+
"warnings": {
|
|
203
|
+
"type": "boolean",
|
|
204
|
+
"description": "Show a full-screen overlay in the browser when there are compiler warnings."
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
]
|
|
209
|
+
},
|
|
210
|
+
"needClientEntry": {
|
|
211
|
+
"anyOf": [
|
|
212
|
+
{
|
|
213
|
+
"type": "boolean"
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
"instanceof": "Function"
|
|
217
|
+
}
|
|
218
|
+
],
|
|
219
|
+
"description": "Tells devServer to inject a client entry."
|
|
220
|
+
},
|
|
221
|
+
"needHotEntry": {
|
|
222
|
+
"anyOf": [
|
|
223
|
+
{
|
|
224
|
+
"type": "boolean"
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
"instanceof": "Function"
|
|
228
|
+
}
|
|
229
|
+
],
|
|
230
|
+
"description": "Tells devServer to inject a Hot Module Replacement entry."
|
|
85
231
|
}
|
|
86
|
-
|
|
232
|
+
},
|
|
233
|
+
"description": "Specifies client properties. https://webpack.js.org/configuration/dev-server/#devserverclient",
|
|
234
|
+
"additionalProperties": false
|
|
87
235
|
},
|
|
88
|
-
"
|
|
89
|
-
"type": "boolean"
|
|
236
|
+
"compress": {
|
|
237
|
+
"type": "boolean",
|
|
238
|
+
"description": "Enable gzip compression for everything served. https://webpack.js.org/configuration/dev-server/#devservercompress"
|
|
90
239
|
},
|
|
91
|
-
"
|
|
92
|
-
"type": "
|
|
93
|
-
"
|
|
94
|
-
"type": "string"
|
|
95
|
-
}
|
|
240
|
+
"devMiddleware": {
|
|
241
|
+
"type": "object",
|
|
242
|
+
"description": "Provide options to webpack-dev-middleware which handles webpack assets. https://webpack.js.org/configuration/dev-server/#devserverdevmiddleware"
|
|
96
243
|
},
|
|
97
|
-
"
|
|
244
|
+
"firewall": {
|
|
98
245
|
"anyOf": [
|
|
99
246
|
{
|
|
100
|
-
"type": "
|
|
101
|
-
},
|
|
102
|
-
{
|
|
103
|
-
"instanceof": "RegExp"
|
|
247
|
+
"type": "boolean"
|
|
104
248
|
},
|
|
105
249
|
{
|
|
106
|
-
"
|
|
250
|
+
"type": "array",
|
|
251
|
+
"items": {
|
|
252
|
+
"type": "string"
|
|
253
|
+
},
|
|
254
|
+
"minItems": 1
|
|
107
255
|
}
|
|
108
|
-
]
|
|
109
|
-
|
|
110
|
-
"fs": {
|
|
111
|
-
"type": "object"
|
|
256
|
+
],
|
|
257
|
+
"description": "Defines routes which are enabled by default, on by default and allows localhost. https://webpack.js.org/configuration/dev-server/#devserverfirewall"
|
|
112
258
|
},
|
|
113
259
|
"headers": {
|
|
114
|
-
"type": "object"
|
|
260
|
+
"type": "object",
|
|
261
|
+
"description": "Adds headers to all responses. https://webpack.js.org/configuration/dev-server/#devserverheaders"
|
|
115
262
|
},
|
|
116
263
|
"historyApiFallback": {
|
|
117
264
|
"anyOf": [
|
|
@@ -121,7 +268,8 @@
|
|
|
121
268
|
{
|
|
122
269
|
"type": "object"
|
|
123
270
|
}
|
|
124
|
-
]
|
|
271
|
+
],
|
|
272
|
+
"description": "When using the HTML5 History API, the index.html page will likely have to be served in place of any 404 responses. https://webpack.js.org/configuration/dev-server/#devserverhistoryapifallback"
|
|
125
273
|
},
|
|
126
274
|
"host": {
|
|
127
275
|
"anyOf": [
|
|
@@ -131,144 +279,133 @@
|
|
|
131
279
|
{
|
|
132
280
|
"type": "null"
|
|
133
281
|
}
|
|
134
|
-
]
|
|
282
|
+
],
|
|
283
|
+
"description": "Specify a host to use. If you want your server to be accessible externally. https://webpack.js.org/configuration/dev-server/#devserverhost"
|
|
135
284
|
},
|
|
136
285
|
"hot": {
|
|
137
|
-
"type": "boolean"
|
|
138
|
-
},
|
|
139
|
-
"hotOnly": {
|
|
140
|
-
"type": "boolean"
|
|
141
|
-
},
|
|
142
|
-
"http2": {
|
|
143
|
-
"type": "boolean"
|
|
144
|
-
},
|
|
145
|
-
"https": {
|
|
146
|
-
"anyOf": [
|
|
147
|
-
{
|
|
148
|
-
"type": "object"
|
|
149
|
-
},
|
|
150
|
-
{
|
|
151
|
-
"type": "boolean"
|
|
152
|
-
}
|
|
153
|
-
]
|
|
154
|
-
},
|
|
155
|
-
"index": {
|
|
156
|
-
"type": "string"
|
|
157
|
-
},
|
|
158
|
-
"injectClient": {
|
|
159
286
|
"anyOf": [
|
|
160
287
|
{
|
|
161
288
|
"type": "boolean"
|
|
162
289
|
},
|
|
163
290
|
{
|
|
164
|
-
"
|
|
291
|
+
"enum": ["only"]
|
|
165
292
|
}
|
|
166
|
-
]
|
|
293
|
+
],
|
|
294
|
+
"description": "Enable webpack's Hot Module Replacement feature. https://webpack.js.org/configuration/dev-server/#devserverhot"
|
|
167
295
|
},
|
|
168
|
-
"
|
|
169
|
-
"
|
|
170
|
-
|
|
171
|
-
"type": "boolean"
|
|
172
|
-
},
|
|
173
|
-
{
|
|
174
|
-
"instanceof": "Function"
|
|
175
|
-
}
|
|
176
|
-
]
|
|
177
|
-
},
|
|
178
|
-
"inline": {
|
|
179
|
-
"type": "boolean"
|
|
296
|
+
"http2": {
|
|
297
|
+
"type": "boolean",
|
|
298
|
+
"description": "Serve over HTTP/2 using spdy. https://webpack.js.org/configuration/dev-server/#devserverhttp2"
|
|
180
299
|
},
|
|
181
|
-
"
|
|
300
|
+
"https": {
|
|
182
301
|
"anyOf": [
|
|
183
302
|
{
|
|
184
|
-
"type": "
|
|
303
|
+
"type": "boolean"
|
|
185
304
|
},
|
|
186
305
|
{
|
|
187
|
-
"
|
|
306
|
+
"type": "object",
|
|
307
|
+
"additionalProperties": false,
|
|
308
|
+
"properties": {
|
|
309
|
+
"passphrase": {
|
|
310
|
+
"type": "string",
|
|
311
|
+
"description": "Passphrase for a pfx file."
|
|
312
|
+
},
|
|
313
|
+
"requestCert": {
|
|
314
|
+
"type": "boolean",
|
|
315
|
+
"description": "Request for an SSL certificate."
|
|
316
|
+
},
|
|
317
|
+
"cacert": {
|
|
318
|
+
"anyOf": [
|
|
319
|
+
{
|
|
320
|
+
"type": "string"
|
|
321
|
+
},
|
|
322
|
+
{
|
|
323
|
+
"instanceof": "Buffer"
|
|
324
|
+
}
|
|
325
|
+
],
|
|
326
|
+
"description": "Path to an SSL CA certificate."
|
|
327
|
+
},
|
|
328
|
+
"key": {
|
|
329
|
+
"anyOf": [
|
|
330
|
+
{
|
|
331
|
+
"type": "string"
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
"instanceof": "Buffer"
|
|
335
|
+
}
|
|
336
|
+
],
|
|
337
|
+
"description": "Path to an SSL key."
|
|
338
|
+
},
|
|
339
|
+
"pfx": {
|
|
340
|
+
"anyOf": [
|
|
341
|
+
{
|
|
342
|
+
"type": "string"
|
|
343
|
+
},
|
|
344
|
+
{
|
|
345
|
+
"instanceof": "Buffer"
|
|
346
|
+
}
|
|
347
|
+
],
|
|
348
|
+
"description": "Path to an SSL pfx file."
|
|
349
|
+
},
|
|
350
|
+
"cert": {
|
|
351
|
+
"anyOf": [
|
|
352
|
+
{
|
|
353
|
+
"type": "string"
|
|
354
|
+
},
|
|
355
|
+
{
|
|
356
|
+
"instanceof": "Buffer"
|
|
357
|
+
}
|
|
358
|
+
],
|
|
359
|
+
"description": "Path to an SSL certificate."
|
|
360
|
+
}
|
|
361
|
+
}
|
|
188
362
|
}
|
|
189
|
-
]
|
|
190
|
-
|
|
191
|
-
"lazy": {
|
|
192
|
-
"type": "boolean"
|
|
363
|
+
],
|
|
364
|
+
"description": "By default, dev-server will be served over HTTP. It can optionally be served over HTTP/2 with HTTPS. https://webpack.js.org/configuration/dev-server/#devserverhttps"
|
|
193
365
|
},
|
|
194
366
|
"liveReload": {
|
|
195
|
-
"type": "boolean"
|
|
196
|
-
|
|
197
|
-
"log": {
|
|
198
|
-
"instanceof": "Function"
|
|
199
|
-
},
|
|
200
|
-
"logLevel": {
|
|
201
|
-
"enum": ["info", "warn", "error", "debug", "trace", "silent"]
|
|
367
|
+
"type": "boolean",
|
|
368
|
+
"description": "By default, the dev-server will reload/refresh the page when file changes are detected. https://webpack.js.org/configuration/dev-server/#devserverlivereload"
|
|
202
369
|
},
|
|
203
|
-
"
|
|
204
|
-
"
|
|
205
|
-
|
|
206
|
-
"mimeTypes": {
|
|
207
|
-
"type": "object"
|
|
370
|
+
"onAfterSetupMiddleware": {
|
|
371
|
+
"instanceof": "Function",
|
|
372
|
+
"description": "Provides the ability to execute custom middleware after all other middleware internally within the server. https://webpack.js.org/configuration/dev-server/#devserverafter"
|
|
208
373
|
},
|
|
209
|
-
"
|
|
210
|
-
"
|
|
374
|
+
"onBeforeSetupMiddleware": {
|
|
375
|
+
"instanceof": "Function",
|
|
376
|
+
"description": "Provides the ability to execute custom middleware prior to all other middleware internally within the server. https://webpack.js.org/configuration/dev-server/#devserverbefore"
|
|
211
377
|
},
|
|
212
378
|
"onListening": {
|
|
213
|
-
"instanceof": "Function"
|
|
379
|
+
"instanceof": "Function",
|
|
380
|
+
"description": "Provides an option to execute a custom function when webpack-dev-server starts listening for connections on a port. https://webpack.js.org/configuration/dev-server/#onlistening"
|
|
214
381
|
},
|
|
215
382
|
"open": {
|
|
216
383
|
"anyOf": [
|
|
217
384
|
{
|
|
218
|
-
"
|
|
385
|
+
"$ref": "#/definitions/OpenBoolean"
|
|
219
386
|
},
|
|
220
387
|
{
|
|
221
|
-
"
|
|
388
|
+
"$ref": "#/definitions/OpenString"
|
|
222
389
|
},
|
|
223
390
|
{
|
|
224
|
-
"
|
|
225
|
-
}
|
|
226
|
-
]
|
|
227
|
-
},
|
|
228
|
-
"openPage": {
|
|
229
|
-
"anyOf": [
|
|
230
|
-
{
|
|
231
|
-
"type": "string"
|
|
391
|
+
"$ref": "#/definitions/OpenObject"
|
|
232
392
|
},
|
|
233
393
|
{
|
|
234
394
|
"type": "array",
|
|
235
395
|
"items": {
|
|
236
|
-
"
|
|
396
|
+
"anyOf": [
|
|
397
|
+
{
|
|
398
|
+
"$ref": "#/definitions/OpenString"
|
|
399
|
+
},
|
|
400
|
+
{
|
|
401
|
+
"$ref": "#/definitions/OpenObject"
|
|
402
|
+
}
|
|
403
|
+
]
|
|
237
404
|
},
|
|
238
405
|
"minItems": 1
|
|
239
406
|
}
|
|
240
|
-
]
|
|
241
|
-
|
|
242
|
-
"overlay": {
|
|
243
|
-
"anyOf": [
|
|
244
|
-
{
|
|
245
|
-
"type": "boolean"
|
|
246
|
-
},
|
|
247
|
-
{
|
|
248
|
-
"type": "object",
|
|
249
|
-
"properties": {
|
|
250
|
-
"errors": {
|
|
251
|
-
"type": "boolean"
|
|
252
|
-
},
|
|
253
|
-
"warnings": {
|
|
254
|
-
"type": "boolean"
|
|
255
|
-
}
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
]
|
|
259
|
-
},
|
|
260
|
-
"pfx": {
|
|
261
|
-
"anyOf": [
|
|
262
|
-
{
|
|
263
|
-
"type": "string"
|
|
264
|
-
},
|
|
265
|
-
{
|
|
266
|
-
"instanceof": "Buffer"
|
|
267
|
-
}
|
|
268
|
-
]
|
|
269
|
-
},
|
|
270
|
-
"pfxPassphrase": {
|
|
271
|
-
"type": "string"
|
|
407
|
+
],
|
|
408
|
+
"description": "Tells dev-server to open the browser after server had been started. Set it to true to open your default browser. https://webpack.js.org/configuration/dev-server/#devserveropen"
|
|
272
409
|
},
|
|
273
410
|
"port": {
|
|
274
411
|
"anyOf": [
|
|
@@ -281,13 +418,8 @@
|
|
|
281
418
|
{
|
|
282
419
|
"type": "null"
|
|
283
420
|
}
|
|
284
|
-
]
|
|
285
|
-
|
|
286
|
-
"profile": {
|
|
287
|
-
"type": "boolean"
|
|
288
|
-
},
|
|
289
|
-
"progress": {
|
|
290
|
-
"type": "boolean"
|
|
421
|
+
],
|
|
422
|
+
"description": "Specify a port number to listen for requests on. https://webpack.js.org/configuration/dev-server/#devserverport"
|
|
291
423
|
},
|
|
292
424
|
"proxy": {
|
|
293
425
|
"anyOf": [
|
|
@@ -308,76 +440,44 @@
|
|
|
308
440
|
},
|
|
309
441
|
"minItems": 1
|
|
310
442
|
}
|
|
311
|
-
]
|
|
443
|
+
],
|
|
444
|
+
"description": "Proxying some URLs can be useful when you have a separate API backend development server and you want to send API requests on the same domain. https://webpack.js.org/configuration/dev-server/#devserverproxy"
|
|
312
445
|
},
|
|
313
446
|
"public": {
|
|
314
|
-
"type": "string"
|
|
315
|
-
|
|
316
|
-
"publicPath": {
|
|
317
|
-
"type": "string"
|
|
318
|
-
},
|
|
319
|
-
"quiet": {
|
|
320
|
-
"type": "boolean"
|
|
321
|
-
},
|
|
322
|
-
"reporter": {
|
|
323
|
-
"instanceof": "Function"
|
|
324
|
-
},
|
|
325
|
-
"requestCert": {
|
|
326
|
-
"type": "boolean"
|
|
327
|
-
},
|
|
328
|
-
"serveIndex": {
|
|
329
|
-
"type": "boolean"
|
|
330
|
-
},
|
|
331
|
-
"serverSideRender": {
|
|
332
|
-
"type": "boolean"
|
|
333
|
-
},
|
|
334
|
-
"setup": {
|
|
335
|
-
"instanceof": "Function"
|
|
336
|
-
},
|
|
337
|
-
"sockHost": {
|
|
338
|
-
"type": "string"
|
|
447
|
+
"type": "string",
|
|
448
|
+
"description": "When using dev server and you're proxying dev-server, the client script does not always know where to connect to. It will try to guess the URL of the server based on window.location, but if that fails you'll need to use this. https://webpack.js.org/configuration/dev-server/#devserverpublic"
|
|
339
449
|
},
|
|
340
|
-
"
|
|
341
|
-
"type": "
|
|
450
|
+
"setupExitSignals": {
|
|
451
|
+
"type": "boolean",
|
|
452
|
+
"description": "It takes a boolean and if true (default on CLI), the server will close and exit the process on SIGINT and SIGTERM. https://webpack.js.org/configuration/dev-server/#devserversetupexitsignals"
|
|
342
453
|
},
|
|
343
|
-
"
|
|
454
|
+
"static": {
|
|
344
455
|
"anyOf": [
|
|
345
456
|
{
|
|
346
|
-
"type": "
|
|
457
|
+
"type": "boolean"
|
|
347
458
|
},
|
|
348
459
|
{
|
|
349
|
-
"
|
|
460
|
+
"$ref": "#/definitions/StaticString"
|
|
350
461
|
},
|
|
351
462
|
{
|
|
352
|
-
"
|
|
353
|
-
}
|
|
354
|
-
]
|
|
355
|
-
},
|
|
356
|
-
"socket": {
|
|
357
|
-
"type": "string"
|
|
358
|
-
},
|
|
359
|
-
"staticOptions": {
|
|
360
|
-
"type": "object"
|
|
361
|
-
},
|
|
362
|
-
"stats": {
|
|
363
|
-
"anyOf": [
|
|
364
|
-
{
|
|
365
|
-
"type": "object"
|
|
463
|
+
"$ref": "#/definitions/StaticObject"
|
|
366
464
|
},
|
|
367
465
|
{
|
|
368
|
-
"type": "
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
466
|
+
"type": "array",
|
|
467
|
+
"items": {
|
|
468
|
+
"anyOf": [
|
|
469
|
+
{
|
|
470
|
+
"$ref": "#/definitions/StaticString"
|
|
471
|
+
},
|
|
472
|
+
{
|
|
473
|
+
"$ref": "#/definitions/StaticObject"
|
|
474
|
+
}
|
|
475
|
+
]
|
|
476
|
+
},
|
|
477
|
+
"minItems": 1
|
|
379
478
|
}
|
|
380
|
-
]
|
|
479
|
+
],
|
|
480
|
+
"description": "It is possible to configure advanced options for serving static files from directory. See the Express documentation for the possible options. https://webpack.js.org/configuration/dev-server/#devserverstatic"
|
|
381
481
|
},
|
|
382
482
|
"transportMode": {
|
|
383
483
|
"anyOf": [
|
|
@@ -403,96 +503,32 @@
|
|
|
403
503
|
{
|
|
404
504
|
"enum": ["sockjs", "ws"]
|
|
405
505
|
}
|
|
406
|
-
]
|
|
506
|
+
],
|
|
507
|
+
"description": "This option allows us either to choose the current devServer transport mode for client/server individually or to provide custom client/server implementation. https://webpack.js.org/configuration/dev-server/#devservertransportmode"
|
|
407
508
|
},
|
|
408
|
-
"
|
|
409
|
-
"type": "boolean"
|
|
410
|
-
},
|
|
411
|
-
"warn": {
|
|
412
|
-
"instanceof": "Function"
|
|
413
|
-
},
|
|
414
|
-
"watchContentBase": {
|
|
415
|
-
"type": "boolean"
|
|
416
|
-
},
|
|
417
|
-
"watchOptions": {
|
|
418
|
-
"type": "object"
|
|
419
|
-
},
|
|
420
|
-
"writeToDisk": {
|
|
509
|
+
"watchFiles": {
|
|
421
510
|
"anyOf": [
|
|
422
511
|
{
|
|
423
|
-
"
|
|
512
|
+
"$ref": "#/definitions/WatchFilesString"
|
|
513
|
+
},
|
|
514
|
+
{
|
|
515
|
+
"$ref": "#/definitions/WatchFilesObject"
|
|
424
516
|
},
|
|
425
517
|
{
|
|
426
|
-
"
|
|
518
|
+
"type": "array",
|
|
519
|
+
"items": {
|
|
520
|
+
"anyOf": [
|
|
521
|
+
{
|
|
522
|
+
"$ref": "#/definitions/WatchFilesString"
|
|
523
|
+
},
|
|
524
|
+
{
|
|
525
|
+
"$ref": "#/definitions/WatchFilesObject"
|
|
526
|
+
}
|
|
527
|
+
]
|
|
528
|
+
}
|
|
427
529
|
}
|
|
428
|
-
]
|
|
429
|
-
|
|
430
|
-
},
|
|
431
|
-
"errorMessage": {
|
|
432
|
-
"properties": {
|
|
433
|
-
"after": "should be {Function} (https://webpack.js.org/configuration/dev-server/#devserverafter)",
|
|
434
|
-
"allowedHosts": "should be {Array} (https://webpack.js.org/configuration/dev-server/#devserverallowedhosts)",
|
|
435
|
-
"before": "should be {Function} (https://webpack.js.org/configuration/dev-server/#devserverbefore)",
|
|
436
|
-
"bonjour": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverbonjour)",
|
|
437
|
-
"ca": "should be {String|Buffer}",
|
|
438
|
-
"cert": "should be {String|Buffer}",
|
|
439
|
-
"clientLogLevel": "should be {String} and equal to one of the allowed values\n\n [ 'none', 'silent', 'info', 'debug', 'trace', 'error', 'warning', 'warn' ]\n\n (https://webpack.js.org/configuration/dev-server/#devserverclientloglevel)",
|
|
440
|
-
"compress": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devservercompress)",
|
|
441
|
-
"contentBase": "should be {Number|String|Array} (https://webpack.js.org/configuration/dev-server/#devservercontentbase)",
|
|
442
|
-
"disableHostCheck": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverdisablehostcheck)",
|
|
443
|
-
"features": "should be {Array}",
|
|
444
|
-
"filename": "should be {String|RegExp|Function} (https://webpack.js.org/configuration/dev-server/#devserverfilename-)",
|
|
445
|
-
"fs": "should be {Object} (https://github.com/webpack/webpack-dev-middleware#fs)",
|
|
446
|
-
"headers": "should be {Object} (https://webpack.js.org/configuration/dev-server/#devserverheaders-)",
|
|
447
|
-
"historyApiFallback": "should be {Boolean|Object} (https://webpack.js.org/configuration/dev-server/#devserverhistoryapifallback)",
|
|
448
|
-
"host": "should be {String|Null} (https://webpack.js.org/configuration/dev-server/#devserverhost)",
|
|
449
|
-
"hot": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverhot)",
|
|
450
|
-
"hotOnly": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverhotonly)",
|
|
451
|
-
"http2": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverhttp2)",
|
|
452
|
-
"https": "should be {Object|Boolean} (https://webpack.js.org/configuration/dev-server/#devserverhttps)",
|
|
453
|
-
"index": "should be {String} (https://webpack.js.org/configuration/dev-server/#devserverindex)",
|
|
454
|
-
"injectClient": "should be {Boolean|Function} (https://webpack.js.org/configuration/dev-server/#devserverinjectclient)",
|
|
455
|
-
"injectHot": "should be {Boolean|Function} (https://webpack.js.org/configuration/dev-server/#devserverinjecthot)",
|
|
456
|
-
"inline": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverinline)",
|
|
457
|
-
"key": "should be {String|Buffer}",
|
|
458
|
-
"lazy": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverlazy-)",
|
|
459
|
-
"liveReload": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverlivereload-)",
|
|
460
|
-
"log": "should be {Function}",
|
|
461
|
-
"logLevel": "should be {String} and equal to one of the allowed values\n\n [ 'info', 'warn', 'error', 'debug', 'trace', 'silent' ]\n\n (https://github.com/webpack/webpack-dev-middleware#loglevel)",
|
|
462
|
-
"logTime": "should be {Boolean} (https://github.com/webpack/webpack-dev-middleware#logtime)",
|
|
463
|
-
"mimeTypes": "should be {Object} (https://webpack.js.org/configuration/dev-server/#devservermimetypes-)",
|
|
464
|
-
"noInfo": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devservernoinfo-)",
|
|
465
|
-
"onListening": "should be {Function} (https://webpack.js.org/configuration/dev-server/#onlistening)",
|
|
466
|
-
"open": "should be {String|Boolean|Object} (https://webpack.js.org/configuration/dev-server/#devserveropen)",
|
|
467
|
-
"openPage": "should be {String|Array} (https://webpack.js.org/configuration/dev-server/#devserveropenpage)",
|
|
468
|
-
"overlay": "should be {Boolean|Object} (https://webpack.js.org/configuration/dev-server/#devserveroverlay)",
|
|
469
|
-
"pfx": "should be {String|Buffer} (https://webpack.js.org/configuration/dev-server/#devserverpfx)",
|
|
470
|
-
"pfxPassphrase": "should be {String} (https://webpack.js.org/configuration/dev-server/#devserverpfxpassphrase)",
|
|
471
|
-
"port": "should be {Number|String|Null} (https://webpack.js.org/configuration/dev-server/#devserverport)",
|
|
472
|
-
"profile": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverprofile)",
|
|
473
|
-
"progress": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverprogress---cli-only)",
|
|
474
|
-
"proxy": "should be {Object|Array} (https://webpack.js.org/configuration/dev-server/#devserverproxy)",
|
|
475
|
-
"public": "should be {String} (https://webpack.js.org/configuration/dev-server/#devserverpublic)",
|
|
476
|
-
"publicPath": "should be {String} (https://webpack.js.org/configuration/dev-server/#devserverpublicpath-)",
|
|
477
|
-
"quiet": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverquiet-)",
|
|
478
|
-
"reporter": "should be {Function} (https://github.com/webpack/webpack-dev-middleware#reporter)",
|
|
479
|
-
"requestCert": "should be {Boolean}",
|
|
480
|
-
"contentBasePublicPath": "should be {String|Array} (https://webpack.js.org/configuration/dev-server/#devservercontentbasepublicpath)",
|
|
481
|
-
"serveIndex": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverserveindex)",
|
|
482
|
-
"serverSideRender": "should be {Boolean} (https://github.com/webpack/webpack-dev-middleware#serversiderender)",
|
|
483
|
-
"setup": "should be {Function} (https://webpack.js.org/configuration/dev-server/#devserversetup)",
|
|
484
|
-
"sockHost": "should be {String|Null} (https://webpack.js.org/configuration/dev-server/#devserversockhost)",
|
|
485
|
-
"sockPath": "should be {String} (https://webpack.js.org/configuration/dev-server/#devserversockpath)",
|
|
486
|
-
"sockPort": "should be {Number|String|Null} (https://webpack.js.org/configuration/dev-server/#devserversockport)",
|
|
487
|
-
"socket": "should be {String} (https://webpack.js.org/configuration/dev-server/#devserversocket)",
|
|
488
|
-
"staticOptions": "should be {Object} (https://webpack.js.org/configuration/dev-server/#devserverstaticoptions)",
|
|
489
|
-
"stats": "should be {Object|Boolean} (https://webpack.js.org/configuration/dev-server/#devserverstats-)",
|
|
490
|
-
"transportMode": "should be {String|Object} (https://webpack.js.org/configuration/dev-server/#devservertransportmode)",
|
|
491
|
-
"useLocalIp": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserveruselocalip)",
|
|
492
|
-
"warn": "should be {Function}",
|
|
493
|
-
"watchContentBase": "should be {Boolean} (https://webpack.js.org/configuration/dev-server/#devserverwatchcontentbase)",
|
|
494
|
-
"watchOptions": "should be {Object} (https://webpack.js.org/configuration/dev-server/#devserverwatchoptions-)",
|
|
495
|
-
"writeToDisk": "should be {Boolean|Function} (https://webpack.js.org/configuration/dev-server/#devserverwritetodisk-)"
|
|
530
|
+
],
|
|
531
|
+
"description": "List of files to watch for file changes and serve. https://webpack.js.org/configuration/dev-server/#devserverwatchfiles"
|
|
496
532
|
}
|
|
497
533
|
},
|
|
498
534
|
"additionalProperties": false
|