two-stroke 1.1.4 → 1.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/package.json +14 -14
- package/src/index.ts +9 -1
package/package.json
CHANGED
|
@@ -9,18 +9,18 @@
|
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@anatine/zod-openapi": "^2.2.6",
|
|
12
|
-
"@asteasolutions/zod-to-openapi": "^7.
|
|
13
|
-
"@cloudflare/workers-types": "^4.
|
|
14
|
-
"@sentry/cli": "^2.
|
|
15
|
-
"@typescript-eslint/eslint-plugin": "^8.8.
|
|
16
|
-
"@typescript-eslint/parser": "^8.8.
|
|
17
|
-
"@vitest/coverage-v8": "^2.1.
|
|
12
|
+
"@asteasolutions/zod-to-openapi": "^7.2.0",
|
|
13
|
+
"@cloudflare/workers-types": "^4.20241011.0",
|
|
14
|
+
"@sentry/cli": "^2.37.0",
|
|
15
|
+
"@typescript-eslint/eslint-plugin": "^8.8.1",
|
|
16
|
+
"@typescript-eslint/parser": "^8.8.1",
|
|
17
|
+
"@vitest/coverage-v8": "^2.1.3",
|
|
18
18
|
"eslint-config-prettier": "^9.1.0",
|
|
19
|
-
"eslint-config-two-stroke": "^1.1.
|
|
19
|
+
"eslint-config-two-stroke": "^1.1.5",
|
|
20
20
|
"eslint-config-typescript": "^3.0.0",
|
|
21
|
-
"jose": "^5.9.
|
|
21
|
+
"jose": "^5.9.4",
|
|
22
22
|
"jwk-subtle": "^1.0.7",
|
|
23
|
-
"miniflare": "^3.
|
|
23
|
+
"miniflare": "^3.20241004.0",
|
|
24
24
|
"openapi-fetch": "^0.12.2",
|
|
25
25
|
"openapi-typescript": "^7.4.1",
|
|
26
26
|
"openapi3-ts": "^4.4.0",
|
|
@@ -51,13 +51,13 @@
|
|
|
51
51
|
"name": "two-stroke",
|
|
52
52
|
"packageManager": "yarn@4.3.0",
|
|
53
53
|
"type": "module",
|
|
54
|
-
"version": "1.1.
|
|
54
|
+
"version": "1.1.6",
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"@types/eslint": "^9.6.1",
|
|
57
|
-
"@types/node": "^22.7.
|
|
58
|
-
"eslint": "^9.
|
|
57
|
+
"@types/node": "^22.7.5",
|
|
58
|
+
"eslint": "^9.12.0",
|
|
59
59
|
"prettier": "^3.3.3",
|
|
60
|
-
"typescript": "^5.6.
|
|
61
|
-
"vitest": "^2.1.
|
|
60
|
+
"typescript": "^5.6.3",
|
|
61
|
+
"vitest": "^2.1.3"
|
|
62
62
|
}
|
|
63
63
|
}
|
package/src/index.ts
CHANGED
|
@@ -381,11 +381,18 @@ export function twoStroke<T extends Env>(title: string, release: string) {
|
|
|
381
381
|
params,
|
|
382
382
|
});
|
|
383
383
|
},
|
|
384
|
-
delete<
|
|
384
|
+
delete<
|
|
385
|
+
O extends ZodSchema,
|
|
386
|
+
A,
|
|
387
|
+
P extends string,
|
|
388
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
389
|
+
PP extends ZodObject<any> | undefined,
|
|
390
|
+
>(
|
|
385
391
|
auth: Route<T, A>["auth"],
|
|
386
392
|
path: P,
|
|
387
393
|
output: O,
|
|
388
394
|
handler: Handler<T, undefined, O, A, P>,
|
|
395
|
+
params?: PP,
|
|
389
396
|
) {
|
|
390
397
|
routes.push({
|
|
391
398
|
auth,
|
|
@@ -396,6 +403,7 @@ export function twoStroke<T extends Env>(title: string, release: string) {
|
|
|
396
403
|
),
|
|
397
404
|
output,
|
|
398
405
|
handler,
|
|
406
|
+
params,
|
|
399
407
|
});
|
|
400
408
|
},
|
|
401
409
|
};
|