forked from cap-js-community/websocket
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpackage.json
183 lines (183 loc) · 5.88 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
{
"name": "@cap-js-community/websocket",
"version": "1.0.2",
"description": "WebSocket adapter for CDS",
"homepage": "https://cap.cloud.sap/",
"engines": {
"node": ">=18"
},
"author": "Oliver Klemenz <[email protected]>",
"keywords": [
"CAP",
"CDS",
"WS",
"WebSocket",
"Socket.IO"
],
"files": [
"src",
"cds-plugin.js",
"CHANGELOG.md"
],
"main": "src/index.js",
"types": "src/index.d.ts",
"scripts": {
"run": "cd ./test/_env && cds-serve",
"start": "npm start --prefix=./test/_env",
"start:socketio": "npm run start:socketio --prefix=./test/_env",
"start:uaa": "npm run start:uaa --prefix=./test/_env",
"start:socketio:uaa": "npm run start:socketio:uaa --prefix=./test/_env",
"start:approuter": "PORT=5001 npm start --prefix=./test/_env/approuter",
"test": "jest",
"test:update": "npm test -- -u",
"lint": "npm run eslint && npm run prettier",
"lint:ci": "npm run eslint:ci && npm run prettier:ci",
"eslint": "eslint --fix .",
"eslint:ci": "eslint .",
"prettier": "prettier \"**/*.{js,json,md,yml,yaml}\" --write --log-level error",
"prettier:ci": "prettier \"**/*.{js,json,md,yml,yaml}\" --check",
"upgrade-lock": "rm -rf package-lock.json node_modules && npm i --package-lock=true",
"prepareRelease": "npm prune --production",
"audit": "npm audit --only=prod"
},
"dependencies": {
"@sap/xsenv": "^5.1.0",
"cookie": "^0.6.0",
"express": "^4.19.2",
"redis": "^4.6.14",
"socket.io": "^4.7.5",
"ws": "^8.17.1"
},
"devDependencies": {
"@cap-js-community/websocket": "./",
"@cap-js/sqlite": "^1.7.1",
"@eslint/js": "^9.5.0",
"@sap/cds": "^7.9.2",
"@sap/cds-dk": "^7.9.3",
"@sap/xssec": "^4.1.0",
"@socket.io/redis-adapter": "^8.3.0",
"@socket.io/redis-streams-adapter": "^0.2.2",
"@types/express": "^4.17.21",
"eslint": "^9.5.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-jest": "^28.6.0",
"eslint-plugin-n": "^17.9.0",
"globals": "^15.6.0",
"jest": "^29.7.0",
"passport": "^0.7.0",
"prettier": "^3.3.2",
"socket.io-client": "^4.7.5"
},
"license": "Apache-2.0",
"repository": {
"type": "git",
"url": "https://github.com/cap-js-community/websocket.git"
},
"cds": {
"requires": {
"kinds": {
"websocket-ws": {
"impl": "@cap-js-community/websocket/src/socket/ws.js"
},
"websocket-socket.io": {
"impl": "@cap-js-community/websocket/src/socket/socket.io.js"
}
}
},
"schema": {
"cds": {
"websocket": {
"oneOf": [
{
"type": "object",
"properties": {
"kind": {
"type": "string",
"description": "Websocket implementation kind",
"enum": [
"ws",
"socket.io"
],
"default": "ws"
},
"impl": {
"type": "string",
"description": "Websocket implementation path"
},
"options": {
"type": "object",
"description": "Websocket implementation configuration options",
"additionalProperties": true
},
"adapter": {
"type": "object",
"description": "Websocket adapter configuration options",
"properties": {
"impl": {
"type": "string",
"description": "Websocket adapter implementation",
"enum": [
"redis",
"@socket.io/redis-adapter",
"@socket.io/redis-streams-adapter"
]
},
"options": {
"type": "object",
"description": "Websocket adapter implementation options",
"properties": {
"key": {
"type": "string",
"description": "Websocket adapter channel prefix",
"default": "websocket"
}
},
"additionalProperties": true
},
"config": {
"type": "object",
"description": "Websocket adapter implementation configurations (i.e. Redis client options)",
"additionalProperties": true
},
"active": {
"type": "boolean",
"description": "Enable websocket adapter",
"default": true
},
"local": {
"type": "boolean",
"description": "Enable websocket adapter in local environment",
"default": false
},
"vcap": {
"type": "object",
"description": "VCAP service environment",
"properties": {
"label": {
"type": "string",
"description": "VCAP service label"
},
"tag": {
"type": "string",
"description": "VCAP service tag"
}
},
"additionalProperties": true
}
}
}
}
},
{
"type": "boolean",
"description": "Set to false to disable websockets"
}
]
}
}
},
"websocket": {
"kind": "ws"
}
}
}