@yydb/redis 0.0.0 → 0.0.1
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.
- package/README.md +4 -3
- package/package.json +29 -5
- package/src/index.ts +21 -0
package/README.md
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
# 🔴 `@yydb/redis`
|
|
2
|
+
|
|
3
|
+
Redis driver under the **SQL Studio** brand. Studio UI uses Key Browser /
|
|
4
|
+
Command Console for this Data Source.
|
package/package.json
CHANGED
|
@@ -1,10 +1,34 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yydb/redis",
|
|
3
|
-
"version": "0.0.
|
|
4
|
-
"description": "
|
|
5
|
-
"
|
|
6
|
-
"
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"description": "Redis driver and workbench surfaces for SQL Studio — 0.0.1 Developer Preview",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"license": "MPL-2.0",
|
|
7
|
+
"sideEffects": false,
|
|
8
|
+
"main": "./src/index.ts",
|
|
9
|
+
"types": "./src/index.ts",
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"types": "./src/index.ts",
|
|
13
|
+
"import": "./src/index.ts",
|
|
14
|
+
"default": "./src/index.ts"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
7
17
|
"files": [
|
|
18
|
+
"src",
|
|
8
19
|
"README.md"
|
|
9
|
-
]
|
|
20
|
+
],
|
|
21
|
+
"scripts": {
|
|
22
|
+
"typecheck": "tsc --noEmit -p tsconfig.json"
|
|
23
|
+
},
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@yydb/sql-studio-protocol": "0.0.1"
|
|
26
|
+
},
|
|
27
|
+
"devDependencies": {
|
|
28
|
+
"typescript": "^5.9.2"
|
|
29
|
+
},
|
|
30
|
+
"publishConfig": {
|
|
31
|
+
"access": "public",
|
|
32
|
+
"tag": "dev"
|
|
33
|
+
}
|
|
10
34
|
}
|
package/src/index.ts
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `@yydb/redis` — Redis driver for SQL Studio (Key Browser / Command Console).
|
|
3
|
+
* Product brand is SQL Studio; Redis is a Data Source, not a SQL engine.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import type { StudioDriverRegistration } from "@yydb/sql-studio-protocol";
|
|
7
|
+
|
|
8
|
+
export const DRIVER_ID = "redis" as const;
|
|
9
|
+
|
|
10
|
+
export type RedisFactoryOptions = {
|
|
11
|
+
id: string;
|
|
12
|
+
url: string;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export function redis(options: RedisFactoryOptions): StudioDriverRegistration {
|
|
16
|
+
return {
|
|
17
|
+
id: options.id,
|
|
18
|
+
kind: "redis",
|
|
19
|
+
driver: { url: options.url, kind: DRIVER_ID },
|
|
20
|
+
};
|
|
21
|
+
}
|