@only-chat/in-memory-store 0.2.0-beta.26 → 0.2.0-beta.28

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.
Files changed (2) hide show
  1. package/README.md +24 -1
  2. package/package.json +8 -8
package/README.md CHANGED
@@ -1,2 +1,25 @@
1
1
  # only-chat
2
- This is an in-memory message store implementation for only-chat.
2
+ This is an in-memory message store implementation for only-chat.
3
+
4
+ # Get started
5
+
6
+ ```shell
7
+ npm i --save @only-chat/in-memory-store
8
+ ```
9
+
10
+ ```typescript
11
+ import { initialize as initializeStore, saveInstance } from '@only-chat/in-memory-store';
12
+ import { initialize as initializeClient, WsClient } from '@only-chat/client'
13
+
14
+ ...
15
+
16
+ const store = await initializeStore();
17
+
18
+ const { _id: instanceId } = await saveInstance();
19
+
20
+ initializeClient({queue, store, userStore, instanceId}, logger)
21
+
22
+ const ws = new WebSocketServer({ host, port })
23
+
24
+ ws.on('connection', s => new WsClient(s))
25
+ ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@only-chat/in-memory-store",
3
- "version": "0.2.0-beta.26",
3
+ "version": "0.2.0-beta.28",
4
4
  "description": "In memory storage for only-chat",
5
5
  "homepage": "https://github.com/only-chat/node-backend/packages/stores/memory",
6
6
  "main": "dist/index.js",
@@ -18,14 +18,14 @@
18
18
  "author": "only-chat",
19
19
  "license": "MIT",
20
20
  "devDependencies": {
21
- "@jest/globals": "^29.7.0",
22
- "@only-chat/types": "0.2.0-beta.26",
23
- "@types/jest": "^29.5.12",
24
- "jest": "^29.7.0",
25
- "jest-ts-webcompat-resolver": "^1.0.0",
26
- "ts-jest": "^29.1.4",
21
+ "@jest/globals": "^30.2.0",
22
+ "@only-chat/types": "0.2.0-beta.28",
23
+ "@types/jest": "^30.0.0",
24
+ "jest": "^30.2.0",
25
+ "jest-ts-webcompat-resolver": "^1.0.1",
26
+ "ts-jest": "^29.4.6",
27
27
  "ts-node": "^10.9.2",
28
- "typescript": "^5.9.2"
28
+ "typescript": "^5.9.3"
29
29
  },
30
30
  "files": [
31
31
  "dist/"