dinou 8.1.0 → 8.1.2
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 +15 -0
- package/README.md +1 -1
- package/cli.js +7 -7
- package/dinou/esbuild/react-refresh/esm-hmr/client.js +5 -2
- package/dinou/node/dev.js +34 -3
- package/dinou/node_modules/ws/LICENSE +20 -0
- package/dinou/node_modules/ws/README.md +548 -0
- package/dinou/node_modules/ws/browser.js +8 -0
- package/dinou/node_modules/ws/index.js +22 -0
- package/dinou/node_modules/ws/lib/buffer-util.js +131 -0
- package/dinou/node_modules/ws/lib/constants.js +19 -0
- package/dinou/node_modules/ws/lib/event-target.js +292 -0
- package/dinou/node_modules/ws/lib/extension.js +203 -0
- package/dinou/node_modules/ws/lib/limiter.js +55 -0
- package/dinou/node_modules/ws/lib/permessage-deflate.js +530 -0
- package/dinou/node_modules/ws/lib/receiver.js +743 -0
- package/dinou/node_modules/ws/lib/sender.js +607 -0
- package/dinou/node_modules/ws/lib/stream.js +161 -0
- package/dinou/node_modules/ws/lib/subprotocol.js +62 -0
- package/dinou/node_modules/ws/lib/validation.js +152 -0
- package/dinou/node_modules/ws/lib/websocket-server.js +562 -0
- package/dinou/node_modules/ws/lib/websocket.js +1421 -0
- package/dinou/node_modules/ws/package.json +74 -0
- package/dinou/node_modules/ws/wrapper.mjs +21 -0
- package/dinou/package.json +1 -1
- package/dinou/rollup/react-refresh/esm-hmr/client.js +5 -2
- package/dinou/rollup/react-refresh/rollup-plugin-esm-hmr.js +3 -8
- package/dinou/webpack/helpers/patch-webpack-internals.js +35 -35
- package/package.json +1 -1
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "ws",
|
|
3
|
+
"version": "8.22.0",
|
|
4
|
+
"description": "Simple to use, blazing fast and thoroughly tested websocket client and server for Node.js",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"HyBi",
|
|
7
|
+
"Push",
|
|
8
|
+
"RFC-6455",
|
|
9
|
+
"WebSocket",
|
|
10
|
+
"WebSockets",
|
|
11
|
+
"real-time"
|
|
12
|
+
],
|
|
13
|
+
"homepage": "https://github.com/websockets/ws",
|
|
14
|
+
"bugs": "https://github.com/websockets/ws/issues",
|
|
15
|
+
"repository": {
|
|
16
|
+
"type": "git",
|
|
17
|
+
"url": "git+https://github.com/websockets/ws.git"
|
|
18
|
+
},
|
|
19
|
+
"author": "Einar Otto Stangvik <einaros@gmail.com> (http://2x.io)",
|
|
20
|
+
"license": "MIT",
|
|
21
|
+
"main": "index.js",
|
|
22
|
+
"exports": {
|
|
23
|
+
".": {
|
|
24
|
+
"browser": "./browser.js",
|
|
25
|
+
"import": "./wrapper.mjs",
|
|
26
|
+
"require": "./index.js"
|
|
27
|
+
},
|
|
28
|
+
"./package.json": "./package.json"
|
|
29
|
+
},
|
|
30
|
+
"browser": "browser.js",
|
|
31
|
+
"engines": {
|
|
32
|
+
"node": ">=10.0.0"
|
|
33
|
+
},
|
|
34
|
+
"files": [
|
|
35
|
+
"browser.js",
|
|
36
|
+
"index.js",
|
|
37
|
+
"lib/*.js",
|
|
38
|
+
"wrapper.mjs"
|
|
39
|
+
],
|
|
40
|
+
"scripts": {
|
|
41
|
+
"test": "nyc --reporter=lcov --reporter=text mocha --throw-deprecation test/*.test.js",
|
|
42
|
+
"integration": "mocha --throw-deprecation test/*.integration.js",
|
|
43
|
+
"lint": "eslint . && prettier --check --ignore-path .gitignore \"**/*.{json,md,yaml,yml}\""
|
|
44
|
+
},
|
|
45
|
+
"peerDependencies": {
|
|
46
|
+
"bufferutil": "^4.0.1",
|
|
47
|
+
"utf-8-validate": ">=5.0.2"
|
|
48
|
+
},
|
|
49
|
+
"peerDependenciesMeta": {
|
|
50
|
+
"bufferutil": {
|
|
51
|
+
"optional": true
|
|
52
|
+
},
|
|
53
|
+
"utf-8-validate": {
|
|
54
|
+
"optional": true
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
"devDependencies": {
|
|
58
|
+
"@eslint/js": "^10.0.1",
|
|
59
|
+
"benchmark": "^2.1.4",
|
|
60
|
+
"bufferutil": "^4.0.1",
|
|
61
|
+
"eslint": "^10.0.1",
|
|
62
|
+
"eslint-config-prettier": "^10.0.1",
|
|
63
|
+
"eslint-plugin-prettier": "^5.0.0",
|
|
64
|
+
"globals": "^17.0.0",
|
|
65
|
+
"mocha": "^8.4.0",
|
|
66
|
+
"nyc": "^15.0.0",
|
|
67
|
+
"prettier": "^3.0.0",
|
|
68
|
+
"utf-8-validate": "^6.0.0"
|
|
69
|
+
},
|
|
70
|
+
"allowScripts": {
|
|
71
|
+
"bufferutil": true,
|
|
72
|
+
"utf-8-validate": true
|
|
73
|
+
}
|
|
74
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import createWebSocketStream from './lib/stream.js';
|
|
2
|
+
import extension from './lib/extension.js';
|
|
3
|
+
import PerMessageDeflate from './lib/permessage-deflate.js';
|
|
4
|
+
import Receiver from './lib/receiver.js';
|
|
5
|
+
import Sender from './lib/sender.js';
|
|
6
|
+
import subprotocol from './lib/subprotocol.js';
|
|
7
|
+
import WebSocket from './lib/websocket.js';
|
|
8
|
+
import WebSocketServer from './lib/websocket-server.js';
|
|
9
|
+
|
|
10
|
+
export {
|
|
11
|
+
createWebSocketStream,
|
|
12
|
+
extension,
|
|
13
|
+
PerMessageDeflate,
|
|
14
|
+
Receiver,
|
|
15
|
+
Sender,
|
|
16
|
+
subprotocol,
|
|
17
|
+
WebSocket,
|
|
18
|
+
WebSocketServer
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
export default WebSocket;
|
package/dinou/package.json
CHANGED
|
@@ -77,7 +77,7 @@ class HotModuleState {
|
|
|
77
77
|
_deps = [];
|
|
78
78
|
}
|
|
79
79
|
if (callback === true) {
|
|
80
|
-
callback = () => {};
|
|
80
|
+
callback = () => { };
|
|
81
81
|
}
|
|
82
82
|
const deps = _deps.map((dep) => {
|
|
83
83
|
const ext = dep.split(".").pop();
|
|
@@ -113,7 +113,10 @@ async function applyUpdate(id) {
|
|
|
113
113
|
const clean = id ? id.split("?")[0] : "";
|
|
114
114
|
const normId = clean.startsWith("/") ? clean : "/" + clean;
|
|
115
115
|
const state = REGISTERED_MODULES[normId] || REGISTERED_MODULES[clean] || REGISTERED_MODULES[id];
|
|
116
|
-
if (!state
|
|
116
|
+
if (!state) {
|
|
117
|
+
return true;
|
|
118
|
+
}
|
|
119
|
+
if (state.isDeclined) {
|
|
117
120
|
return false;
|
|
118
121
|
}
|
|
119
122
|
|
|
@@ -133,7 +133,7 @@ function esmHmrPlugin() {
|
|
|
133
133
|
});
|
|
134
134
|
}
|
|
135
135
|
|
|
136
|
-
// 3. Fallback: match chunk filename with
|
|
136
|
+
// 3. Fallback: match chunk filename with exact normalized relative path of changedId
|
|
137
137
|
if (!isChangedByJs) {
|
|
138
138
|
const chunkFileNameLower = fileName.toLowerCase().replace(/\.[jt]sx?$/, "");
|
|
139
139
|
for (const changedId of changedIds) {
|
|
@@ -142,12 +142,7 @@ function esmHmrPlugin() {
|
|
|
142
142
|
.replace(/\.[jt]sx?$/, "")
|
|
143
143
|
.replace(/[^a-zA-Z0-9_-]/g, "_")
|
|
144
144
|
.toLowerCase();
|
|
145
|
-
if (relClean && chunkFileNameLower.
|
|
146
|
-
isChangedByJs = true;
|
|
147
|
-
break;
|
|
148
|
-
}
|
|
149
|
-
const baseName = path.basename(changedId).replace(/\.[jt]sx?$/, "").toLowerCase();
|
|
150
|
-
if (baseName.length > 2 && baseName !== "page" && baseName !== "layout" && baseName !== "index" && chunkFileNameLower.includes(baseName)) {
|
|
145
|
+
if (relClean && (chunkFileNameLower === relClean || chunkFileNameLower.endsWith("/" + relClean))) {
|
|
151
146
|
isChangedByJs = true;
|
|
152
147
|
break;
|
|
153
148
|
}
|
|
@@ -235,7 +230,7 @@ const closeHmrServer = () => {
|
|
|
235
230
|
if (activeServer) {
|
|
236
231
|
try {
|
|
237
232
|
activeServer.close();
|
|
238
|
-
} catch (e) {}
|
|
233
|
+
} catch (e) { }
|
|
239
234
|
activeServer = null;
|
|
240
235
|
activeHmrEngine = null;
|
|
241
236
|
}
|
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import module from "node:module";
|
|
2
|
-
|
|
3
|
-
// Compatibility shim for Webpack 5.112+ internal file reorganization with react-server-dom-webpack
|
|
4
|
-
const originalResolveFilename = module._resolveFilename;
|
|
5
|
-
if (originalResolveFilename) {
|
|
6
|
-
module._resolveFilename = function (request, parent, isMain, options) {
|
|
7
|
-
if (request === "webpack/lib/dependencies/ModuleDependency") {
|
|
8
|
-
try {
|
|
9
|
-
return originalResolveFilename.call(this, request, parent, isMain, options);
|
|
10
|
-
} catch {
|
|
11
|
-
return originalResolveFilename.call(
|
|
12
|
-
this,
|
|
13
|
-
"webpack/lib/dependencies/core/ModuleDependency",
|
|
14
|
-
parent,
|
|
15
|
-
isMain,
|
|
16
|
-
options
|
|
17
|
-
);
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
if (request === "webpack/lib/Template") {
|
|
21
|
-
try {
|
|
22
|
-
return originalResolveFilename.call(this, request, parent, isMain, options);
|
|
23
|
-
} catch {
|
|
24
|
-
return originalResolveFilename.call(
|
|
25
|
-
this,
|
|
26
|
-
"webpack/lib/template/Template",
|
|
27
|
-
parent,
|
|
28
|
-
isMain,
|
|
29
|
-
options
|
|
30
|
-
);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
return originalResolveFilename.call(this, request, parent, isMain, options);
|
|
34
|
-
};
|
|
35
|
-
}
|
|
1
|
+
import module from "node:module";
|
|
2
|
+
|
|
3
|
+
// Compatibility shim for Webpack 5.112+ internal file reorganization with react-server-dom-webpack
|
|
4
|
+
const originalResolveFilename = module._resolveFilename;
|
|
5
|
+
if (originalResolveFilename) {
|
|
6
|
+
module._resolveFilename = function (request, parent, isMain, options) {
|
|
7
|
+
if (request === "webpack/lib/dependencies/ModuleDependency") {
|
|
8
|
+
try {
|
|
9
|
+
return originalResolveFilename.call(this, request, parent, isMain, options);
|
|
10
|
+
} catch {
|
|
11
|
+
return originalResolveFilename.call(
|
|
12
|
+
this,
|
|
13
|
+
"webpack/lib/dependencies/core/ModuleDependency",
|
|
14
|
+
parent,
|
|
15
|
+
isMain,
|
|
16
|
+
options
|
|
17
|
+
);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
if (request === "webpack/lib/Template") {
|
|
21
|
+
try {
|
|
22
|
+
return originalResolveFilename.call(this, request, parent, isMain, options);
|
|
23
|
+
} catch {
|
|
24
|
+
return originalResolveFilename.call(
|
|
25
|
+
this,
|
|
26
|
+
"webpack/lib/template/Template",
|
|
27
|
+
parent,
|
|
28
|
+
isMain,
|
|
29
|
+
options
|
|
30
|
+
);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
return originalResolveFilename.call(this, request, parent, isMain, options);
|
|
34
|
+
};
|
|
35
|
+
}
|
package/package.json
CHANGED