@spoosh/plugin-deduplication 0.1.4 → 0.1.6
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 +2 -2
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Request deduplication plugin for Spoosh - prevents duplicate in-flight requests.
|
|
4
4
|
|
|
5
|
-
**[Documentation](https://spoosh.dev/docs/plugins/deduplication)** · **Requirements:** TypeScript >= 5.0 · **Peer Dependencies:** `@spoosh/core`
|
|
5
|
+
**[Documentation](https://spoosh.dev/docs/react/plugins/deduplication)** · **Requirements:** TypeScript >= 5.0 · **Peer Dependencies:** `@spoosh/core`
|
|
6
6
|
|
|
7
7
|
## Installation
|
|
8
8
|
|
|
@@ -24,7 +24,7 @@ const client = new Spoosh<ApiSchema, Error>("/api").use([
|
|
|
24
24
|
deduplicationPlugin({ write: "in-flight" }),
|
|
25
25
|
]);
|
|
26
26
|
|
|
27
|
-
useRead((api) => api.
|
|
27
|
+
useRead((api) => api("posts").GET(), { dedupe: false });
|
|
28
28
|
```
|
|
29
29
|
|
|
30
30
|
## Options
|
package/dist/index.d.mts
CHANGED
|
@@ -40,7 +40,7 @@ declare module "@spoosh/core" {
|
|
|
40
40
|
*
|
|
41
41
|
* @param config - Plugin configuration
|
|
42
42
|
*
|
|
43
|
-
* @see {@link https://spoosh.dev/docs/plugins/deduplication | Deduplication Plugin Documentation}
|
|
43
|
+
* @see {@link https://spoosh.dev/docs/react/plugins/deduplication | Deduplication Plugin Documentation}
|
|
44
44
|
*
|
|
45
45
|
* @example
|
|
46
46
|
* ```ts
|
|
@@ -53,7 +53,7 @@ declare module "@spoosh/core" {
|
|
|
53
53
|
* ]);
|
|
54
54
|
*
|
|
55
55
|
* // Per-query override
|
|
56
|
-
* useRead((api) => api.
|
|
56
|
+
* useRead((api) => api("posts").GET(), {
|
|
57
57
|
* dedupe: false,
|
|
58
58
|
* });
|
|
59
59
|
* ```
|
package/dist/index.d.ts
CHANGED
|
@@ -40,7 +40,7 @@ declare module "@spoosh/core" {
|
|
|
40
40
|
*
|
|
41
41
|
* @param config - Plugin configuration
|
|
42
42
|
*
|
|
43
|
-
* @see {@link https://spoosh.dev/docs/plugins/deduplication | Deduplication Plugin Documentation}
|
|
43
|
+
* @see {@link https://spoosh.dev/docs/react/plugins/deduplication | Deduplication Plugin Documentation}
|
|
44
44
|
*
|
|
45
45
|
* @example
|
|
46
46
|
* ```ts
|
|
@@ -53,7 +53,7 @@ declare module "@spoosh/core" {
|
|
|
53
53
|
* ]);
|
|
54
54
|
*
|
|
55
55
|
* // Per-query override
|
|
56
|
-
* useRead((api) => api.
|
|
56
|
+
* useRead((api) => api("posts").GET(), {
|
|
57
57
|
* dedupe: false,
|
|
58
58
|
* });
|
|
59
59
|
* ```
|
package/package.json
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spoosh/plugin-deduplication",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.6",
|
|
4
4
|
"description": "Request deduplication plugin for Spoosh - prevents duplicate in-flight requests",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
8
|
-
"url": "git+https://github.com/
|
|
8
|
+
"url": "git+https://github.com/spooshdev/spoosh.git",
|
|
9
9
|
"directory": "packages/plugin-deduplication"
|
|
10
10
|
},
|
|
11
11
|
"bugs": {
|
|
12
|
-
"url": "https://github.com/
|
|
12
|
+
"url": "https://github.com/spooshdev/spoosh/issues"
|
|
13
13
|
},
|
|
14
|
-
"homepage": "https://spoosh.dev/react/
|
|
14
|
+
"homepage": "https://spoosh.dev/docs/react/plugins/deduplication",
|
|
15
15
|
"publishConfig": {
|
|
16
16
|
"access": "public"
|
|
17
17
|
},
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"@spoosh/core": ">=0.4.0"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"@spoosh/core": "0.
|
|
39
|
+
"@spoosh/core": "0.10.0",
|
|
40
40
|
"@spoosh/test-utils": "0.1.5"
|
|
41
41
|
},
|
|
42
42
|
"scripts": {
|