@pluv/platform-node 0.38.13 → 0.39.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.38.13 build /home/runner/work/pluv/pluv/packages/platform-node
2
+ > @pluv/platform-node@0.39.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
@@ -9,10 +9,10 @@
9
9
  ESM Build start
10
10
  CJS Build start
11
11
  ESM dist/index.mjs 8.78 KB
12
- ESM ⚡️ Build success in 84ms
12
+ ESM ⚡️ Build success in 88ms
13
13
  CJS dist/index.js 10.56 KB
14
- CJS ⚡️ Build success in 85ms
14
+ CJS ⚡️ Build success in 83ms
15
15
  DTS Build start
16
- DTS ⚡️ Build success in 5340ms
16
+ DTS ⚡️ Build success in 5381ms
17
17
  DTS dist/index.d.mts 5.91 KB
18
18
  DTS dist/index.d.ts 5.91 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,22 @@
1
1
  # @pluv/platform-node
2
2
 
3
+ ## 0.39.0
4
+
5
+ ### Patch Changes
6
+
7
+ - 78a9c85: Update error codes for invalid websocket connection data to return a 1003 status code instead of 1011.
8
+ - Updated dependencies [fe6e239]
9
+ - Updated dependencies [737d508]
10
+ - @pluv/io@0.39.0
11
+ - @pluv/types@0.39.0
12
+
13
+ ## 0.38.14
14
+
15
+ ### Patch Changes
16
+
17
+ - @pluv/io@0.38.14
18
+ - @pluv/types@0.38.14
19
+
3
20
  ## 0.38.13
4
21
 
5
22
  ### Patch Changes
package/dist/index.js CHANGED
@@ -76,15 +76,15 @@ var import_path_to_regexp = require("path-to-regexp");
76
76
  var import_ws = require("ws");
77
77
  var handle = (ws) => ({
78
78
  invalidEndpoint: () => {
79
- ws.close(1011, "Invalid WebSocket endpoint");
79
+ ws.close(1003, "Invalid WebSocket endpoint");
80
80
  return { matched: false };
81
81
  },
82
82
  invalidRoom: () => {
83
- ws.close(1011, "Invalid room name");
83
+ ws.close(1003, "Invalid room name");
84
84
  return { matched: true };
85
85
  },
86
86
  invalidToken: () => {
87
- ws.close(1011, "Invalid authentication token");
87
+ ws.close(1003, "Invalid authentication token");
88
88
  return { matched: true };
89
89
  }
90
90
  });
package/dist/index.mjs CHANGED
@@ -41,15 +41,15 @@ import { match } from "path-to-regexp";
41
41
  import { Server as WsServer } from "ws";
42
42
  var handle = (ws) => ({
43
43
  invalidEndpoint: () => {
44
- ws.close(1011, "Invalid WebSocket endpoint");
44
+ ws.close(1003, "Invalid WebSocket endpoint");
45
45
  return { matched: false };
46
46
  },
47
47
  invalidRoom: () => {
48
- ws.close(1011, "Invalid room name");
48
+ ws.close(1003, "Invalid room name");
49
49
  return { matched: true };
50
50
  },
51
51
  invalidToken: () => {
52
- ws.close(1011, "Invalid authentication token");
52
+ ws.close(1003, "Invalid authentication token");
53
53
  return { matched: true };
54
54
  }
55
55
  });
@@ -0,0 +1,4 @@
1
+ import { config } from "eslint-config-pluv/base";
2
+
3
+ /** @type {import("eslint").Linter.Config} */
4
+ export default config;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pluv/platform-node",
3
- "version": "0.38.13",
3
+ "version": "0.39.0",
4
4
  "description": "@pluv/io adapter for node.js",
5
5
  "author": "leedavidcs",
6
6
  "license": "MIT",
@@ -17,19 +17,19 @@
17
17
  "access": "public"
18
18
  },
19
19
  "dependencies": {
20
- "@types/node": "^22.14.0",
20
+ "@types/node": "^22.14.1",
21
21
  "@types/ws": "^8.18.1",
22
22
  "path-to-regexp": "^8.2.0",
23
- "@pluv/io": "^0.38.13",
24
- "@pluv/types": "^0.38.13"
23
+ "@pluv/io": "^0.39.0",
24
+ "@pluv/types": "^0.39.0"
25
25
  },
26
26
  "devDependencies": {
27
- "eslint": "^8.57.1",
27
+ "eslint": "^9.24.0",
28
28
  "tsup": "^8.4.0",
29
29
  "typescript": "^5.8.3",
30
30
  "ws": "^8.18.1",
31
- "@pluv/tsconfig": "^0.38.13",
32
- "eslint-config-pluv": "^0.38.13"
31
+ "@pluv/tsconfig": "^0.39.0",
32
+ "eslint-config-pluv": "^0.39.0"
33
33
  },
34
34
  "peerDependencies": {
35
35
  "ws": "^8.0.0"
@@ -37,7 +37,7 @@
37
37
  "scripts": {
38
38
  "build": "tsup src/index.ts --format esm,cjs --dts",
39
39
  "dev": "tsup src/index.ts --format esm,cjs --watch --dts",
40
- "lint": "eslint src/**/*.ts* --fix",
40
+ "lint": "eslint src/**/*.ts* --fix --max-warnings 0",
41
41
  "clean": "rm -rf .turbo && rm -rf node_modules && rm -rf dist"
42
42
  }
43
43
  }
@@ -25,17 +25,17 @@ export type CreatePluvHandlerConfig<TPluvServer extends PluvServer<any, any, any
25
25
 
26
26
  const handle = (ws: WebSocket) => ({
27
27
  invalidEndpoint: () => {
28
- ws.close(1011, "Invalid WebSocket endpoint");
28
+ ws.close(1003, "Invalid WebSocket endpoint");
29
29
 
30
30
  return { matched: false };
31
31
  },
32
32
  invalidRoom: () => {
33
- ws.close(1011, "Invalid room name");
33
+ ws.close(1003, "Invalid room name");
34
34
 
35
35
  return { matched: true };
36
36
  },
37
37
  invalidToken: () => {
38
- ws.close(1011, "Invalid authentication token");
38
+ ws.close(1003, "Invalid authentication token");
39
39
 
40
40
  return { matched: true };
41
41
  },
package/.eslintrc.js DELETED
@@ -1,4 +0,0 @@
1
- module.exports = {
2
- root: true,
3
- extends: ["pluv"],
4
- };