webpack-dev-server 4.3.1 → 4.4.0

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/lib/options.json CHANGED
@@ -59,6 +59,9 @@
59
59
  "progress": {
60
60
  "$ref": "#/definitions/ClientProgress"
61
61
  },
62
+ "reconnect": {
63
+ "$ref": "#/definitions/ClientReconnect"
64
+ },
62
65
  "webSocketTransport": {
63
66
  "$ref": "#/definitions/ClientWebSocketTransport"
64
67
  },
@@ -102,6 +105,19 @@
102
105
  "link": "https://webpack.js.org/configuration/dev-server/#progress",
103
106
  "type": "boolean"
104
107
  },
108
+ "ClientReconnect": {
109
+ "description": "Tells dev-server the number of times it should try to reconnect the client.",
110
+ "link": "https://webpack.js.org/configuration/dev-server/#reconnect",
111
+ "anyOf": [
112
+ {
113
+ "type": "boolean"
114
+ },
115
+ {
116
+ "type": "number",
117
+ "minimum": 0
118
+ }
119
+ ]
120
+ },
105
121
  "ClientWebSocketTransport": {
106
122
  "anyOf": [
107
123
  {
@@ -205,11 +221,11 @@
205
221
  "properties": {
206
222
  "passphrase": {
207
223
  "type": "string",
208
- "description": "Passphrase for a pfx file."
224
+ "description": "Passphrase for a pfx file. Deprecated, it will be removed in favor of the `server.options.passphrase` option."
209
225
  },
210
226
  "requestCert": {
211
227
  "type": "boolean",
212
- "description": "Request for an SSL certificate."
228
+ "description": "Request for an SSL certificate. Deprecated, it will be removed in favor of the `server.options.requestCert` option."
213
229
  },
214
230
  "ca": {
215
231
  "anyOf": [
@@ -233,7 +249,7 @@
233
249
  "instanceof": "Buffer"
234
250
  }
235
251
  ],
236
- "description": "Path to an SSL CA certificate or content of an SSL CA certificate."
252
+ "description": "Path to an SSL CA certificate or content of an SSL CA certificate. Deprecated, it will be removed in favor of the `server.options.ca` option."
237
253
  },
238
254
  "cacert": {
239
255
  "anyOf": [
@@ -257,7 +273,7 @@
257
273
  "instanceof": "Buffer"
258
274
  }
259
275
  ],
260
- "description": "Path to an SSL CA certificate or content of an SSL CA certificate."
276
+ "description": "Path to an SSL CA certificate or content of an SSL CA certificate. Deprecated, it will be removed in favor of the `server.options.cacert` option."
261
277
  },
262
278
  "cert": {
263
279
  "anyOf": [
@@ -281,7 +297,7 @@
281
297
  "instanceof": "Buffer"
282
298
  }
283
299
  ],
284
- "description": "Path to an SSL certificate or content of an SSL certificate."
300
+ "description": "Path to an SSL certificate or content of an SSL certificate. Deprecated, it will be removed in favor of the `server.options.cert` option."
285
301
  },
286
302
  "crl": {
287
303
  "anyOf": [
@@ -305,7 +321,7 @@
305
321
  "instanceof": "Buffer"
306
322
  }
307
323
  ],
308
- "description": "Path to PEM formatted CRLs (Certificate Revocation Lists) or content of PEM formatted CRLs (Certificate Revocation Lists)."
324
+ "description": "Path to PEM formatted CRLs (Certificate Revocation Lists) or content of PEM formatted CRLs (Certificate Revocation Lists). Deprecated, it will be removed in favor of the `server.options.crl` option."
309
325
  },
310
326
  "key": {
311
327
  "anyOf": [
@@ -333,7 +349,7 @@
333
349
  "instanceof": "Buffer"
334
350
  }
335
351
  ],
336
- "description": "Path to an SSL key or content of an SSL key."
352
+ "description": "Path to an SSL key or content of an SSL key. Deprecated, it will be removed in favor of the `server.options.key` option."
337
353
  },
338
354
  "pfx": {
339
355
  "anyOf": [
@@ -361,7 +377,7 @@
361
377
  "instanceof": "Buffer"
362
378
  }
363
379
  ],
364
- "description": "Path to an SSL pfx file or content of an SSL pfx file."
380
+ "description": "Path to an SSL pfx file or content of an SSL pfx file. Deprecated, it will be removed in favor of the `server.options.pfx` option."
365
381
  }
366
382
  }
367
383
  }
@@ -615,6 +631,215 @@
615
631
  "description": "Allows to proxy requests, can be useful when you have a separate API backend development server and you want to send API requests on the same domain.",
616
632
  "link": "https://webpack.js.org/configuration/dev-server/#devserverproxy"
617
633
  },
634
+ "Server": {
635
+ "anyOf": [
636
+ {
637
+ "$ref": "#/definitions/ServerEnum"
638
+ },
639
+ {
640
+ "$ref": "#/definitions/ServerString"
641
+ },
642
+ {
643
+ "$ref": "#/definitions/ServerObject"
644
+ }
645
+ ],
646
+ "link": "https://webpack.js.org/configuration/dev-server/#devserverserver",
647
+ "description": "Allows to set server and options (by default 'http')."
648
+ },
649
+ "ServerType": {
650
+ "enum": ["http", "https", "spdy"]
651
+ },
652
+ "ServerEnum": {
653
+ "enum": ["http", "https", "spdy"],
654
+ "cli": {
655
+ "exclude": true
656
+ }
657
+ },
658
+ "ServerString": {
659
+ "type": "string",
660
+ "minLength": 1,
661
+ "cli": {
662
+ "exclude": true
663
+ }
664
+ },
665
+ "ServerObject": {
666
+ "type": "object",
667
+ "properties": {
668
+ "type": {
669
+ "$ref": "#/definitions/ServerType"
670
+ },
671
+ "options": {
672
+ "$ref": "#/definitions/ServerOptions"
673
+ }
674
+ },
675
+ "additionalProperties": false
676
+ },
677
+ "ServerOptions": {
678
+ "type": "object",
679
+ "additionalProperties": true,
680
+ "properties": {
681
+ "passphrase": {
682
+ "type": "string",
683
+ "description": "Passphrase for a pfx file."
684
+ },
685
+ "requestCert": {
686
+ "type": "boolean",
687
+ "description": "Request for an SSL certificate."
688
+ },
689
+ "ca": {
690
+ "anyOf": [
691
+ {
692
+ "type": "array",
693
+ "items": {
694
+ "anyOf": [
695
+ {
696
+ "type": "string"
697
+ },
698
+ {
699
+ "instanceof": "Buffer"
700
+ }
701
+ ]
702
+ }
703
+ },
704
+ {
705
+ "type": "string"
706
+ },
707
+ {
708
+ "instanceof": "Buffer"
709
+ }
710
+ ],
711
+ "description": "Path to an SSL CA certificate or content of an SSL CA certificate."
712
+ },
713
+ "cacert": {
714
+ "anyOf": [
715
+ {
716
+ "type": "array",
717
+ "items": {
718
+ "anyOf": [
719
+ {
720
+ "type": "string"
721
+ },
722
+ {
723
+ "instanceof": "Buffer"
724
+ }
725
+ ]
726
+ }
727
+ },
728
+ {
729
+ "type": "string"
730
+ },
731
+ {
732
+ "instanceof": "Buffer"
733
+ }
734
+ ],
735
+ "description": "Path to an SSL CA certificate or content of an SSL CA certificate."
736
+ },
737
+ "cert": {
738
+ "anyOf": [
739
+ {
740
+ "type": "array",
741
+ "items": {
742
+ "anyOf": [
743
+ {
744
+ "type": "string"
745
+ },
746
+ {
747
+ "instanceof": "Buffer"
748
+ }
749
+ ]
750
+ }
751
+ },
752
+ {
753
+ "type": "string"
754
+ },
755
+ {
756
+ "instanceof": "Buffer"
757
+ }
758
+ ],
759
+ "description": "Path to an SSL certificate or content of an SSL certificate."
760
+ },
761
+ "crl": {
762
+ "anyOf": [
763
+ {
764
+ "type": "array",
765
+ "items": {
766
+ "anyOf": [
767
+ {
768
+ "type": "string"
769
+ },
770
+ {
771
+ "instanceof": "Buffer"
772
+ }
773
+ ]
774
+ }
775
+ },
776
+ {
777
+ "type": "string"
778
+ },
779
+ {
780
+ "instanceof": "Buffer"
781
+ }
782
+ ],
783
+ "description": "Path to PEM formatted CRLs (Certificate Revocation Lists) or content of PEM formatted CRLs (Certificate Revocation Lists)."
784
+ },
785
+ "key": {
786
+ "anyOf": [
787
+ {
788
+ "type": "array",
789
+ "items": {
790
+ "anyOf": [
791
+ {
792
+ "type": "string"
793
+ },
794
+ {
795
+ "instanceof": "Buffer"
796
+ },
797
+ {
798
+ "type": "object",
799
+ "additionalProperties": true
800
+ }
801
+ ]
802
+ }
803
+ },
804
+ {
805
+ "type": "string"
806
+ },
807
+ {
808
+ "instanceof": "Buffer"
809
+ }
810
+ ],
811
+ "description": "Path to an SSL key or content of an SSL key."
812
+ },
813
+ "pfx": {
814
+ "anyOf": [
815
+ {
816
+ "type": "array",
817
+ "items": {
818
+ "anyOf": [
819
+ {
820
+ "type": "string"
821
+ },
822
+ {
823
+ "instanceof": "Buffer"
824
+ },
825
+ {
826
+ "type": "object",
827
+ "additionalProperties": true
828
+ }
829
+ ]
830
+ }
831
+ },
832
+ {
833
+ "type": "string"
834
+ },
835
+ {
836
+ "instanceof": "Buffer"
837
+ }
838
+ ],
839
+ "description": "Path to an SSL pfx file or content of an SSL pfx file."
840
+ }
841
+ }
842
+ },
618
843
  "SetupExitSignals": {
619
844
  "type": "boolean",
620
845
  "description": "Allows to close dev server and exit the process on SIGINT and SIGTERM signals (enabled by default for CLI).",
@@ -790,8 +1015,18 @@
790
1015
  "description": "Allows to set web socket server and options (by default 'ws').",
791
1016
  "link": "https://webpack.js.org/configuration/dev-server/#devserverwebsocketserver"
792
1017
  },
1018
+ "WebSocketServerType": {
1019
+ "enum": ["sockjs", "ws"]
1020
+ },
793
1021
  "WebSocketServerEnum": {
794
- "enum": [false, "sockjs", "ws"]
1022
+ "anyOf": [
1023
+ {
1024
+ "enum": [false]
1025
+ },
1026
+ {
1027
+ "$ref": "#/definitions/WebSocketServerType"
1028
+ }
1029
+ ]
795
1030
  },
796
1031
  "WebSocketServerFunction": {
797
1032
  "instanceof": "Function"
@@ -805,7 +1040,7 @@
805
1040
  "type": {
806
1041
  "anyOf": [
807
1042
  {
808
- "$ref": "#/definitions/WebSocketServerEnum"
1043
+ "$ref": "#/definitions/WebSocketServerType"
809
1044
  },
810
1045
  {
811
1046
  "$ref": "#/definitions/WebSocketServerString"
@@ -889,6 +1124,9 @@
889
1124
  "proxy": {
890
1125
  "$ref": "#/definitions/Proxy"
891
1126
  },
1127
+ "server": {
1128
+ "$ref": "#/definitions/Server"
1129
+ },
892
1130
  "setupExitSignals": {
893
1131
  "$ref": "#/definitions/SetupExitSignals"
894
1132
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "webpack-dev-server",
3
- "version": "4.3.1",
3
+ "version": "4.4.0",
4
4
  "description": "Serves a webpack app. Updates the browser on changes.",
5
5
  "bin": "bin/webpack-dev-server.js",
6
6
  "main": "lib/Server.js",
@@ -34,7 +34,7 @@
34
34
  "dependencies": {
35
35
  "ansi-html-community": "^0.0.8",
36
36
  "bonjour": "^3.5.0",
37
- "chokidar": "^3.5.1",
37
+ "chokidar": "^3.5.2",
38
38
  "colorette": "^2.0.10",
39
39
  "compression": "^1.7.4",
40
40
  "connect-history-api-fallback": "^1.6.0",
@@ -74,7 +74,7 @@
74
74
  "body-parser": "^1.19.0",
75
75
  "core-js": "^3.12.1",
76
76
  "css-loader": "^5.2.4",
77
- "eslint": "^7.29.0",
77
+ "eslint": "^8.0.1",
78
78
  "eslint-config-prettier": "^8.3.0",
79
79
  "eslint-config-webpack": "^1.2.5",
80
80
  "eslint-plugin-import": "^2.23.2",