@loopback/socketio 0.6.5 → 0.6.7
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.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Constructor, Context, DecoratorType, MetadataAccessor, MetadataMap } from '@loopback/core';
|
|
2
2
|
import { Socket } from 'socket.io';
|
|
3
|
-
|
|
3
|
+
type SocketIoEventMatcherInfo = {
|
|
4
4
|
matcher: string | RegExp;
|
|
5
5
|
methodNames: string[];
|
|
6
6
|
};
|
|
@@ -2,7 +2,7 @@ import { Application, Binding, BindingFilter, Constructor, Context } from '@loop
|
|
|
2
2
|
import cors from 'cors';
|
|
3
3
|
import { Server, ServerOptions, Socket } from 'socket.io';
|
|
4
4
|
import { SocketIoMetadata } from './decorators';
|
|
5
|
-
export
|
|
5
|
+
export type SockIOMiddleware = (socket: Socket, fn: (err?: any) => void) => void;
|
|
6
6
|
export declare const getNamespaceKeyForName: (name: string) => string;
|
|
7
7
|
/**
|
|
8
8
|
* A binding filter to match socket.io controllers
|
package/dist/types.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { Context, ControllerClass } from '@loopback/core';
|
|
2
2
|
import { HttpServerOptions } from '@loopback/http-server';
|
|
3
|
-
export
|
|
3
|
+
export type SocketIoOptions = HttpServerOptions;
|
|
4
4
|
export interface SocketIoSequence {
|
|
5
5
|
handle(methodName: string, args: unknown[], done: Function): Promise<void>;
|
|
6
6
|
}
|
|
7
|
-
export
|
|
8
|
-
export
|
|
9
|
-
export
|
|
10
|
-
export
|
|
7
|
+
export type SocketIoDoneFunction = (response: unknown) => Promise<void>;
|
|
8
|
+
export type SocketIoInvokeMethod = (context: Context, controller: ControllerClass, methodName: string, args: unknown[]) => unknown;
|
|
9
|
+
export type SocketIoSendMethod = (done: Function, result: unknown) => unknown;
|
|
10
|
+
export type SocketIoRejectMethod = (done: Function, error: Error) => unknown;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@loopback/socketio",
|
|
3
3
|
"description": "LoopBack's WebSocket server based on socket.io",
|
|
4
|
-
"version": "0.6.
|
|
4
|
+
"version": "0.6.7",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"LoopBack",
|
|
7
7
|
"Socket.IO",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"directory": "extensions/socketio"
|
|
22
22
|
},
|
|
23
23
|
"engines": {
|
|
24
|
-
"node": "14 || 16 ||
|
|
24
|
+
"node": "14 || 16 || 18 || 19"
|
|
25
25
|
},
|
|
26
26
|
"scripts": {
|
|
27
27
|
"acceptance": "lb-mocha \"dist/__tests__/acceptance/**/*.js\"",
|
|
@@ -42,27 +42,27 @@
|
|
|
42
42
|
"!*/__tests__"
|
|
43
43
|
],
|
|
44
44
|
"peerDependencies": {
|
|
45
|
-
"@loopback/boot": "^5.0.
|
|
46
|
-
"@loopback/core": "^4.0.
|
|
45
|
+
"@loopback/boot": "^5.0.7",
|
|
46
|
+
"@loopback/core": "^4.0.7"
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
|
-
"@loopback/http-server": "^4.0.
|
|
50
|
-
"@types/cors": "^2.8.
|
|
51
|
-
"@types/lodash": "^4.14.
|
|
49
|
+
"@loopback/http-server": "^4.0.7",
|
|
50
|
+
"@types/cors": "^2.8.13",
|
|
51
|
+
"@types/lodash": "^4.14.191",
|
|
52
52
|
"cors": "^2.8.5",
|
|
53
53
|
"debug": "^4.3.4",
|
|
54
54
|
"lodash": "^4.17.21",
|
|
55
55
|
"socket.io": "^4.5.4"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
|
-
"@loopback/boot": "^5.0.
|
|
59
|
-
"@loopback/build": "^9.0.
|
|
60
|
-
"@loopback/core": "^4.0.
|
|
61
|
-
"@loopback/eslint-config": "^13.0.
|
|
62
|
-
"@loopback/testlab": "^5.0.
|
|
58
|
+
"@loopback/boot": "^5.0.7",
|
|
59
|
+
"@loopback/build": "^9.0.7",
|
|
60
|
+
"@loopback/core": "^4.0.7",
|
|
61
|
+
"@loopback/eslint-config": "^13.0.7",
|
|
62
|
+
"@loopback/testlab": "^5.0.7",
|
|
63
63
|
"@types/debug": "^4.1.7",
|
|
64
64
|
"p-event": "^4.2.0",
|
|
65
65
|
"socket.io-client": "^4.5.4"
|
|
66
66
|
},
|
|
67
|
-
"gitHead": "
|
|
67
|
+
"gitHead": "06cbcba72ceb28ab5033bae80cc5504c80ac53c2"
|
|
68
68
|
}
|