@prismakit/redis 1.0.0 → 1.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 +33 -1
- package/package.json +18 -3
package/README.md
CHANGED
|
@@ -1 +1,33 @@
|
|
|
1
|
-
# @prismakit/redis
|
|
1
|
+
# @prismakit/redis
|
|
2
|
+
|
|
3
|
+
Redis `CacheAdapter` for `@prismakit/core` repositories (ioredis).
|
|
4
|
+
|
|
5
|
+
Fail-open: cache errors do not break reads/writes.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
pnpm add @prismakit/redis ioredis
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Usage
|
|
14
|
+
|
|
15
|
+
```typescript
|
|
16
|
+
import { RedisCacheAdapter } from '@prismakit/redis';
|
|
17
|
+
|
|
18
|
+
const cache = new RedisCacheAdapter({
|
|
19
|
+
prefix: 'myapp',
|
|
20
|
+
// url / client options — see RedisCacheAdapter options
|
|
21
|
+
});
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
Pass `cache` into `createRepository` deps, or into `PrismaKitModule.forRoot({ cache })` when using NestJS.
|
|
25
|
+
|
|
26
|
+
## Docs
|
|
27
|
+
|
|
28
|
+
- [GitHub README](https://github.com/fikiap23/prismakit#readme)
|
|
29
|
+
- [Cache guide](https://github.com/fikiap23/prismakit/blob/master/docs/CACHE.md)
|
|
30
|
+
|
|
31
|
+
## License
|
|
32
|
+
|
|
33
|
+
Apache-2.0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prismakit/redis",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "Redis CacheAdapter for @prismakit/core",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"engines": {
|
|
@@ -23,11 +23,11 @@
|
|
|
23
23
|
"README.md"
|
|
24
24
|
],
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@prismakit/core": "1.0.
|
|
26
|
+
"@prismakit/core": "1.0.1"
|
|
27
27
|
},
|
|
28
28
|
"peerDependencies": {
|
|
29
29
|
"ioredis": ">=5.0.0",
|
|
30
|
-
"@prismakit/core": "1.0.
|
|
30
|
+
"@prismakit/core": "1.0.1"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"ioredis": "^5.6.0",
|
|
@@ -38,6 +38,21 @@
|
|
|
38
38
|
"publishConfig": {
|
|
39
39
|
"access": "public"
|
|
40
40
|
},
|
|
41
|
+
"repository": {
|
|
42
|
+
"type": "git",
|
|
43
|
+
"url": "git+https://github.com/fikiap23/prismakit.git"
|
|
44
|
+
},
|
|
45
|
+
"bugs": {
|
|
46
|
+
"url": "https://github.com/fikiap23/prismakit/issues"
|
|
47
|
+
},
|
|
48
|
+
"homepage": "https://github.com/fikiap23/prismakit/tree/master/packages/redis#readme",
|
|
49
|
+
"keywords": [
|
|
50
|
+
"prisma",
|
|
51
|
+
"redis",
|
|
52
|
+
"cache",
|
|
53
|
+
"ioredis",
|
|
54
|
+
"prismakit"
|
|
55
|
+
],
|
|
41
56
|
"scripts": {
|
|
42
57
|
"build": "tsup src/index.ts --format cjs,esm --dts --clean --sourcemap",
|
|
43
58
|
"test": "vitest run",
|