@elysiajs/jwt 0.2.1 → 0.3.0
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/dist/index.d.ts +2 -1
- package/package.json +4 -4
package/dist/index.d.ts
CHANGED
|
@@ -19,11 +19,12 @@ export interface JWTOption<Name extends string | undefined = 'jwt', Schema exten
|
|
|
19
19
|
exp?: string | number;
|
|
20
20
|
}
|
|
21
21
|
export declare const jwt: <Name extends string = "jwt", Schema extends TSchema | undefined = undefined>({ name, secret, alg, crit, schema, nbf, exp, ...payload }: JWTOption<Name, Schema>) => (app: Elysia) => Elysia<{
|
|
22
|
-
store: Record<
|
|
22
|
+
store: Record<string, unknown>;
|
|
23
23
|
request: { [key in Name extends string ? Name : "jwt"]: {
|
|
24
24
|
sign: (morePayload: UnwrapSchema<Schema, Record<string, string>> & JWTPayloadSpec) => Promise<string>;
|
|
25
25
|
verify: (jwt?: string) => Promise<false | (UnwrapSchema<Schema, Record<string, string>> & JWTPayloadSpec)>;
|
|
26
26
|
}; };
|
|
27
27
|
schema: {};
|
|
28
|
+
meta: Record<typeof import("elysia").SCHEMA, {}> & Record<typeof import("elysia").DEFS, {}> & Record<typeof import("elysia").EXPOSED, {}>;
|
|
28
29
|
}>;
|
|
29
30
|
export default jwt;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elysiajs/jwt",
|
|
3
3
|
"description": "Plugin for Elysia for using JWT Authentication",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.3.0",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "saltyAom",
|
|
7
7
|
"url": "https://github.com/SaltyAom",
|
|
@@ -39,11 +39,11 @@
|
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@elysiajs/cookie": "^0.1.1",
|
|
42
|
-
"@sinclair/typebox": "^0.25.
|
|
42
|
+
"@sinclair/typebox": "^0.25.24",
|
|
43
43
|
"@types/node": "^18.11.7",
|
|
44
|
-
"bun-types": "^0.5.
|
|
44
|
+
"bun-types": "^0.5.7",
|
|
45
45
|
"eslint": "^8.26.0",
|
|
46
|
-
"elysia": "^0.
|
|
46
|
+
"elysia": "^0.3.0-rc.1",
|
|
47
47
|
"typescript": "^4.9.4"
|
|
48
48
|
},
|
|
49
49
|
"peerDependencies": {
|