@pluv/platform-node 0.21.1 → 0.22.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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @pluv/platform-node@0.21.1 build /home/runner/work/pluv/pluv/packages/platform-node
2
+ > @pluv/platform-node@0.22.0 build /home/runner/work/pluv/pluv/packages/platform-node
3
3
  > tsup src/index.ts --format esm,cjs --dts
4
4
 
5
5
  CLI Building entry: src/index.ts
@@ -8,11 +8,11 @@
8
8
  CLI Target: es6
9
9
  ESM Build start
10
10
  CJS Build start
11
- ESM dist/index.mjs 7.58 KB
12
- ESM ⚡️ Build success in 91ms
13
- CJS dist/index.js 9.35 KB
14
- CJS ⚡️ Build success in 92ms
11
+ ESM dist/index.mjs 7.63 KB
12
+ ESM ⚡️ Build success in 102ms
13
+ CJS dist/index.js 9.40 KB
14
+ CJS ⚡️ Build success in 102ms
15
15
  DTS Build start
16
- DTS ⚡️ Build success in 3454ms
17
- DTS dist/index.d.mts 3.56 KB
18
- DTS dist/index.d.ts 3.56 KB
16
+ DTS ⚡️ Build success in 4150ms
17
+ DTS dist/index.d.mts 3.60 KB
18
+ DTS dist/index.d.ts 3.60 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @pluv/platform-node
2
2
 
3
+ ## 0.22.0
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [650e577]
8
+ - @pluv/io@0.22.0
9
+ - @pluv/types@0.22.0
10
+
3
11
  ## 0.21.1
4
12
 
5
13
  ### Patch Changes
package/dist/index.d.mts CHANGED
@@ -12,6 +12,7 @@ declare class NodeWebSocket extends AbstractWebSocket<WebSocket> {
12
12
  get readyState(): 0 | 1 | 2 | 3;
13
13
  get sessionId(): string;
14
14
  get state(): WebSocketSerializedState;
15
+ set state(state: WebSocketSerializedState);
15
16
  constructor(webSocket: WebSocket, config: NodeWebSocketConfig);
16
17
  addEventListener<TType extends keyof AbstractEventMap>(type: TType, handler: AbstractListener<TType>): void;
17
18
  close(code?: number | undefined, reason?: string | undefined): void;
@@ -34,7 +35,7 @@ declare class NodePlatform extends AbstractPlatform<NodeWebSocket> {
34
35
  acceptWebSocket(webSocket: NodeWebSocket): Promise<void>;
35
36
  convertWebSocket(webSocket: WebSocket, config: ConvertWebSocketConfig): NodeWebSocket;
36
37
  getLastPing(webSocket: NodeWebSocket): number | null;
37
- getSerializedState(webSocket: NodeWebSocket): WebSocketSerializedState | null;
38
+ getSerializedState(webSocket: WebSocket): WebSocketSerializedState | null;
38
39
  getSessionId(webSocket: WebSocket): string | null;
39
40
  getWebSockets(): readonly WebSocket[];
40
41
  initialize(config: AbstractPlatformConfig<{}, {}>): this;
package/dist/index.d.ts CHANGED
@@ -12,6 +12,7 @@ declare class NodeWebSocket extends AbstractWebSocket<WebSocket> {
12
12
  get readyState(): 0 | 1 | 2 | 3;
13
13
  get sessionId(): string;
14
14
  get state(): WebSocketSerializedState;
15
+ set state(state: WebSocketSerializedState);
15
16
  constructor(webSocket: WebSocket, config: NodeWebSocketConfig);
16
17
  addEventListener<TType extends keyof AbstractEventMap>(type: TType, handler: AbstractListener<TType>): void;
17
18
  close(code?: number | undefined, reason?: string | undefined): void;
@@ -34,7 +35,7 @@ declare class NodePlatform extends AbstractPlatform<NodeWebSocket> {
34
35
  acceptWebSocket(webSocket: NodeWebSocket): Promise<void>;
35
36
  convertWebSocket(webSocket: WebSocket, config: ConvertWebSocketConfig): NodeWebSocket;
36
37
  getLastPing(webSocket: NodeWebSocket): number | null;
37
- getSerializedState(webSocket: NodeWebSocket): WebSocketSerializedState | null;
38
+ getSerializedState(webSocket: WebSocket): WebSocketSerializedState | null;
38
39
  getSessionId(webSocket: WebSocket): string | null;
39
40
  getWebSockets(): readonly WebSocket[];
40
41
  initialize(config: AbstractPlatformConfig<{}, {}>): this;
package/dist/index.js CHANGED
@@ -176,6 +176,9 @@ var NodeWebSocket = class extends import_io.AbstractWebSocket {
176
176
  get state() {
177
177
  return this._state;
178
178
  }
179
+ set state(state) {
180
+ this._state = state;
181
+ }
179
182
  constructor(webSocket, config) {
180
183
  const { room } = config;
181
184
  super(webSocket, config);
package/dist/index.mjs CHANGED
@@ -142,6 +142,9 @@ var NodeWebSocket = class extends AbstractWebSocket {
142
142
  get state() {
143
143
  return this._state;
144
144
  }
145
+ set state(state) {
146
+ this._state = state;
147
+ }
145
148
  constructor(webSocket, config) {
146
149
  const { room } = config;
147
150
  super(webSocket, config);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pluv/platform-node",
3
- "version": "0.21.1",
3
+ "version": "0.22.0",
4
4
  "description": "@pluv/io adapter for node.js",
5
5
  "author": "leedavidcs",
6
6
  "license": "MIT",
@@ -20,16 +20,16 @@
20
20
  "@types/node": "^22.2.0",
21
21
  "@types/ws": "^8.5.12",
22
22
  "path-to-regexp": "^7.1.0",
23
- "@pluv/io": "^0.21.1",
24
- "@pluv/types": "^0.21.1"
23
+ "@pluv/io": "^0.22.0",
24
+ "@pluv/types": "^0.22.0"
25
25
  },
26
26
  "devDependencies": {
27
27
  "eslint": "^8.57.0",
28
28
  "tsup": "^8.2.4",
29
29
  "typescript": "^5.5.4",
30
30
  "ws": "^8.18.0",
31
- "@pluv/tsconfig": "^0.21.1",
32
- "eslint-config-pluv": "^0.21.1"
31
+ "@pluv/tsconfig": "^0.22.0",
32
+ "eslint-config-pluv": "^0.22.0"
33
33
  },
34
34
  "peerDependencies": {
35
35
  "ws": "^8.0.0"
@@ -42,7 +42,7 @@ export class NodePlatform extends AbstractPlatform<NodeWebSocket> {
42
42
  return null;
43
43
  }
44
44
 
45
- public getSerializedState(webSocket: NodeWebSocket): WebSocketSerializedState | null {
45
+ public getSerializedState(webSocket: WebSocket): WebSocketSerializedState | null {
46
46
  return null;
47
47
  }
48
48
 
@@ -40,6 +40,10 @@ export class NodeWebSocket extends AbstractWebSocket<WebSocket> {
40
40
  return this._state;
41
41
  }
42
42
 
43
+ public set state(state: WebSocketSerializedState) {
44
+ this._state = state;
45
+ }
46
+
43
47
  constructor(webSocket: WebSocket, config: NodeWebSocketConfig) {
44
48
  const { room } = config;
45
49