@rljson/server 0.0.4 → 0.0.6
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/README.architecture.md +1352 -0
- package/README.blog.md +9 -1
- package/README.contributors.md +47 -13
- package/README.md +78 -11
- package/README.public.md +600 -7
- package/README.trouble.md +50 -0
- package/dist/README.architecture.md +1352 -0
- package/dist/README.blog.md +9 -1
- package/dist/README.contributors.md +47 -13
- package/dist/README.md +78 -11
- package/dist/README.public.md +600 -7
- package/dist/README.trouble.md +50 -0
- package/dist/client.d.ts +75 -3
- package/dist/index.d.ts +6 -0
- package/dist/logger.d.ts +115 -0
- package/dist/server.d.ts +148 -7
- package/dist/server.js +858 -118
- package/dist/socket-bundle.d.ts +16 -0
- package/package.json +17 -17
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Socket } from '@rljson/io';
|
|
2
|
+
export type SocketNamespaceBundle = {
|
|
3
|
+
ioUp: Socket;
|
|
4
|
+
ioDown: Socket;
|
|
5
|
+
bsUp: Socket;
|
|
6
|
+
bsDown: Socket;
|
|
7
|
+
};
|
|
8
|
+
export type SocketLike = Socket | SocketNamespaceBundle;
|
|
9
|
+
/**
|
|
10
|
+
* Normalizes a socket input into a full namespace bundle used by the server/client constructors.
|
|
11
|
+
* - If you pass a single Socket (classic setup), it is reused for all namespaces (ioUp/ioDown/bsUp/bsDown).
|
|
12
|
+
* - If you pass an explicit bundle (namespaces already split), the bundle is returned as-is.
|
|
13
|
+
* @param socket - Single socket or pre-split namespace bundle.
|
|
14
|
+
* @returns Normalized namespace bundle for Io/Bs up/down channels.
|
|
15
|
+
*/
|
|
16
|
+
export declare function normalizeSocketBundle(socket: SocketLike): SocketNamespaceBundle;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rljson/server",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.6",
|
|
4
4
|
"description": "Rljson server description",
|
|
5
5
|
"homepage": "https://github.com/rljson/server",
|
|
6
6
|
"bugs": "https://github.com/rljson/server/issues",
|
|
@@ -20,41 +20,41 @@
|
|
|
20
20
|
],
|
|
21
21
|
"type": "module",
|
|
22
22
|
"devDependencies": {
|
|
23
|
-
"@types/node": "^25.
|
|
24
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
25
|
-
"@typescript-eslint/parser": "^8.
|
|
23
|
+
"@types/node": "^25.2.3",
|
|
24
|
+
"@typescript-eslint/eslint-plugin": "^8.56.0",
|
|
25
|
+
"@typescript-eslint/parser": "^8.56.0",
|
|
26
26
|
"@vitest/coverage-v8": "^4.0.18",
|
|
27
27
|
"cross-env": "^10.1.0",
|
|
28
|
-
"eslint": "
|
|
29
|
-
"eslint-plugin-jsdoc": "^62.
|
|
28
|
+
"eslint": "~9.39.2",
|
|
29
|
+
"eslint-plugin-jsdoc": "^62.5.5",
|
|
30
30
|
"eslint-plugin-tsdoc": "^0.5.0",
|
|
31
|
-
"globals": "^17.
|
|
31
|
+
"globals": "^17.3.0",
|
|
32
32
|
"jsdoc": "^4.0.5",
|
|
33
|
-
"read-pkg": "^10.
|
|
33
|
+
"read-pkg": "^10.1.0",
|
|
34
34
|
"socket.io": "^4.8.3",
|
|
35
35
|
"socket.io-client": "^4.8.3",
|
|
36
36
|
"typescript": "~5.9.3",
|
|
37
|
-
"typescript-eslint": "^8.
|
|
37
|
+
"typescript-eslint": "^8.56.0",
|
|
38
38
|
"vite": "^7.3.1",
|
|
39
39
|
"vite-node": "^5.3.0",
|
|
40
40
|
"vite-plugin-dts": "^4.5.4",
|
|
41
|
-
"vite-tsconfig-paths": "^6.
|
|
41
|
+
"vite-tsconfig-paths": "^6.1.1",
|
|
42
42
|
"vitest": "^4.0.18",
|
|
43
43
|
"vitest-dom": "^0.1.1"
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@rljson/bs": "^0.0.
|
|
47
|
-
"@rljson/db": "^0.0.
|
|
46
|
+
"@rljson/bs": "^0.0.21",
|
|
47
|
+
"@rljson/db": "^0.0.14",
|
|
48
48
|
"@rljson/hash": "^0.0.18",
|
|
49
|
-
"@rljson/io": "^0.0.
|
|
49
|
+
"@rljson/io": "^0.0.66",
|
|
50
50
|
"@rljson/json": "^0.0.23",
|
|
51
|
-
"@rljson/rljson": "^0.0.
|
|
51
|
+
"@rljson/rljson": "^0.0.76"
|
|
52
52
|
},
|
|
53
53
|
"scripts": {
|
|
54
|
-
"build": "
|
|
55
|
-
"test": "
|
|
54
|
+
"build": "pnpm exec vite build && tsc && node scripts/copy-readme-to-dist.js",
|
|
55
|
+
"test": "pnpm exec vitest run --coverage && pnpm run lint",
|
|
56
56
|
"prebuild": "npm run test",
|
|
57
|
-
"lint": "
|
|
57
|
+
"lint": "pnpm exec eslint",
|
|
58
58
|
"updateGoldens": "cross-env UPDATE_GOLDENS=true pnpm test"
|
|
59
59
|
}
|
|
60
60
|
}
|