You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* chore: remove SockJSClient and related files from the project
* chore: remove SockJS support and related configurations from the project
* chore: remove SockJS example files and configurations
* chore: remove SockJS support and related tests from the project
* refactor: change sockjs to ws for customclient
* fix: update import typedef
* fix: update snapshots
Signed-off-by: Sebastian Beltran <bjohansebas@gmail.com>
* chore: remove SockJS and related type definitions from package.json and package-lock.json
* refactor: simplify WebSocket session handling in tests
* test: update WebSocket handling in client tests to use CDP sessions
* fix: update snapshot for SSL certificate generation log in server options test
* docs: update migration guide to reflect removal of SockJS support
* refactor: remove SockJS dependency from CustomWebSocketClient
* chore: update puppeteer to version 24.35.0 in package.json
* fix: update import path for webpack config in client tests
* fix: update createCDPSession usage in client tests
* refactor: update session creation and subscription handling in tests
* fix: update webSocketTransport configuration to include webSocketURL and host
---------
Signed-off-by: Sebastian Beltran <bjohansebas@gmail.com>
"SockJS only supports client mode and does not support custom hostname and port options. Please consider using 'ws' if you need to customize these options.",
672
-
);
673
-
}
674
-
675
664
// We are proxying dev server and need to specify custom `hostname`
676
665
if(typeofwebSocketURL.hostname!=="undefined"){
677
666
hostname=webSocketURL.hostname;
678
667
}
679
668
// Web socket server works on custom `hostname`, only for `ws` because `sock-js` is not support custom `hostname`
// could be 'sockjs', 'ws', or a path that should be required
1575
-
if(clientTransport==="sockjs"){
1576
-
clientImplementation=require.resolve(
1577
-
"../client/clients/SockJSClient",
1578
-
);
1579
-
}elseif(clientTransport==="ws"){
1561
+
// could be 'ws', or a path that should be required
1562
+
if(clientTransport==="ws"){
1580
1563
clientImplementation=require.resolve(
1581
1564
"../client/clients/WebSocketClient",
1582
1565
);
@@ -1598,7 +1581,7 @@ class Server {
1598
1581
!isKnownWebSocketServerImplementation
1599
1582
? "When you use custom web socket implementation you must explicitly specify client.webSocketTransport. "
1600
1583
: ""
1601
-
}client.webSocketTransport must be a string denoting a default implementation (e.g. 'sockjs', 'ws') or a full path to a JS file via require.resolve(...) which exports a class `,
1584
+
}client.webSocketTransport must be a string denoting a default implementation (e.g. 'ws') or a full path to a JS file via require.resolve(...) which exports a class `,
1602
1585
);
1603
1586
}
1604
1587
@@ -1621,14 +1604,8 @@ class Server {
1621
1604
)
1622
1605
){
1623
1606
case"string":
1624
-
// Could be 'sockjs', in the future 'ws', or a path that should be required
1607
+
// Could be 'ws', or a path that should be required
1625
1608
if(
1626
-
/** @type {WebSocketServerConfiguration} */(
1627
-
this.options.webSocketServer
1628
-
).type==="sockjs"
1629
-
){
1630
-
implementation=require("./servers/SockJSServer");
1631
-
}elseif(
1632
1609
/** @type {WebSocketServerConfiguration} */(
1633
1610
this.options.webSocketServer
1634
1611
).type==="ws"
@@ -1656,7 +1633,7 @@ class Server {
1656
1633
1657
1634
if(!implementationFound){
1658
1635
thrownewError(
1659
-
"webSocketServer (webSocketServer.type) must be a string denoting a default implementation (e.g. 'ws', 'sockjs'), a full path to "+
1636
+
"webSocketServer (webSocketServer.type) must be a string denoting a default implementation (e.g. 'ws'), a full path to "+
1660
1637
"a JS file which exports a class extending BaseServer (webpack-dev-server/lib/servers/BaseServer.js) "+
1661
1638
"via require.resolve(...), or the class itself which extends BaseServer",
0 commit comments