@aenode/nest-auth 0.0.0-stage → 0.0.36

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.
Files changed (40) hide show
  1. package/README.md +24 -2
  2. package/assets/favicon.svg +1 -0
  3. package/bin/nest-auth.mjs +3 -0
  4. package/dist/index.d.ts +2 -0
  5. package/dist/index.d.ts.map +1 -0
  6. package/dist/index.js +3 -0
  7. package/dist/index.js.map +1 -0
  8. package/dist/lib/guards/auth.guard.d.ts +12 -0
  9. package/dist/lib/guards/auth.guard.d.ts.map +1 -0
  10. package/dist/lib/guards/auth.guard.js +25 -0
  11. package/dist/lib/guards/auth.guard.js.map +1 -0
  12. package/dist/lib/index.d.ts +4 -0
  13. package/dist/lib/index.d.ts.map +1 -0
  14. package/dist/lib/index.js +6 -0
  15. package/dist/lib/index.js.map +1 -0
  16. package/dist/lib/metadata/index.d.ts +2 -0
  17. package/dist/lib/metadata/index.d.ts.map +1 -0
  18. package/dist/lib/metadata/index.js +4 -0
  19. package/dist/lib/metadata/index.js.map +1 -0
  20. package/dist/lib/metadata/public.d.ts +18 -0
  21. package/dist/lib/metadata/public.d.ts.map +1 -0
  22. package/dist/lib/metadata/public.js +21 -0
  23. package/dist/lib/metadata/public.js.map +1 -0
  24. package/dist/lib/nest-auth.d.ts +2 -0
  25. package/dist/lib/nest-auth.d.ts.map +1 -0
  26. package/dist/lib/nest-auth.js +5 -0
  27. package/dist/lib/nest-auth.js.map +1 -0
  28. package/dist/lib/utils/extract-bearer-token.d.ts +10 -0
  29. package/dist/lib/utils/extract-bearer-token.d.ts.map +1 -0
  30. package/dist/lib/utils/extract-bearer-token.js +19 -0
  31. package/dist/lib/utils/extract-bearer-token.js.map +1 -0
  32. package/dist/lib/utils/index.d.ts +2 -0
  33. package/dist/lib/utils/index.d.ts.map +1 -0
  34. package/dist/lib/utils/index.js +4 -0
  35. package/dist/lib/utils/index.js.map +1 -0
  36. package/dist/main.d.ts +3 -0
  37. package/dist/main.d.ts.map +1 -0
  38. package/dist/main.js +4 -0
  39. package/dist/main.js.map +1 -0
  40. package/package.json +63 -4
package/README.md CHANGED
@@ -1,3 +1,25 @@
1
- # Temporary Holding Version
1
+ ![Version](https://img.shields.io/npm/v/@aenode/nest-auth) ![Downloads](https://img.shields.io/npm/dm/@aenode/nest-auth) ![Status](https://img.shields.io/github/actions/workflow/status/aenode/aenode/ci.yml) ![Size](https://img.shields.io/bundlephobia/min/@aenode/nest-auth)
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ <p align="center">
4
+ <img src="https://aenode.github.io/aenode/libs/nest-auth/assets/favicon.svg" alt="aenode Logo" height="128" width="128" style="border-radius: 32px;"/>
5
+ </p>
6
+
7
+ ## @aenode/nest-auth
8
+
9
+ - [ ] Add project description
10
+
11
+ ## Install
12
+
13
+ ```sh
14
+ bun add @aenode/nest-auth
15
+ ```
16
+
17
+ ## Examples
18
+
19
+ ```ts
20
+ const message = 'Hello there';
21
+ ```
22
+
23
+ ---
24
+
25
+ [![CashUp](https://img.shields.io/badge/Cash%20Up-%23EA4AAA.svg?style=for-the-badge&logo=github-sponsors&logoColor=white)](https://cash.app/$puqlib) [![EmainMe](https://img.shields.io/badge/Email-D14836?style=for-the-badge&logo=proton&logoColor=white)](mailto:aenode+aenode+aenode-nest-auth@proton.me)
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" height="48px" width="48px" fill="#5985E1"><path d="M22.93,41.57Q22.5,41.14 22.5,40.5V27.6l-9.1,9.1q-0.44,0.45-1.04,0.45T11.3,36.71t-0.45-1.05T11.3,34.6l9.1-9.1H7.5q-0.64,0-1.07-0.43T6,23.99t0.43-1.07T7.5,22.5H20.45L11.3,13.35q-0.45-0.44-0.45-1.05t0.44-1.05t1.05-0.45t1.06,0.45l9.1,9.1V7.5q0-0.64 0.43-1.07T24.01,6t1.07,0.43T25.5,7.5V20.4l9.15-9.15q0.44-0.45 1.05-0.45t1.05,0.44t0.45,1.05t-0.45,1.06L27.6,22.5H40.5q0.64,0 1.07,0.43T42,24.01t-0.43,1.07T40.5,25.5H27.65l9.1,9.1q0.45,0.44 0.45,1.04T36.76,36.7t-1.05,0.45T34.65,36.7L25.5,27.55V40.5q0,0.64-0.43,1.07T23.99,42t-1.07-0.43Z"/></svg>
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+
3
+ import '../dist/main.js';
@@ -0,0 +1,2 @@
1
+ export * from './lib/index.js';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,3 @@
1
+ export * from './lib/index.js';
2
+
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export * from './lib/index.js';\n"],"names":[],"mappings":"AAAA,cAAc,iBAAiB"}
@@ -0,0 +1,12 @@
1
+ import { type CanActivate, type ExecutionContext } from '@aenode/nest/common';
2
+ import { Reflector } from '@aenode/nest/core';
3
+ /**
4
+ * Check the target resource is public or check the user is authenciated and save the user information to the `request.user`.
5
+ *
6
+ */
7
+ export declare class AuthGuard implements CanActivate {
8
+ protected readonly reflector: Reflector;
9
+ constructor(reflector: Reflector);
10
+ canActivate(context: ExecutionContext): Promise<boolean>;
11
+ }
12
+ //# sourceMappingURL=auth.guard.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"auth.guard.d.ts","sourceRoot":"","sources":["../../../src/lib/guards/auth.guard.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,KAAK,WAAW,EAChB,KAAK,gBAAgB,EACtB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAM9C;;;GAGG;AACH,qBAAa,SAAU,YAAW,WAAW;IAC/B,SAAS,CAAC,QAAQ,CAAC,SAAS,EAAE,SAAS;gBAApB,SAAS,EAAE,SAAS;IAC7C,WAAW,CAAC,OAAO,EAAE,gBAAgB,GAAG,OAAO,CAAC,OAAO,CAAC;CAiB/D"}
@@ -0,0 +1,25 @@
1
+ /* eslint-disable @typescript-eslint/consistent-type-imports */ import { UnauthorizedException } from '@aenode/nest/common';
2
+ import { isPublic } from '../metadata/public.js';
3
+ import { extractBearerToken } from '../utils/index.js';
4
+ /**
5
+ * Check the target resource is public or check the user is authenciated and save the user information to the `request.user`.
6
+ *
7
+ */ export class AuthGuard {
8
+ constructor(reflector){
9
+ this.reflector = reflector;
10
+ }
11
+ async canActivate(context) {
12
+ const req = context.switchToHttp().getRequest();
13
+ const isPublicResource = isPublic(context, this.reflector);
14
+ if (isPublicResource) {
15
+ return true;
16
+ }
17
+ const token = extractBearerToken(req);
18
+ if (!token) {
19
+ throw new UnauthorizedException('Authentication token is not provided');
20
+ }
21
+ return true;
22
+ }
23
+ }
24
+
25
+ //# sourceMappingURL=auth.guard.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/guards/auth.guard.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/consistent-type-imports */\n\nimport {\n UnauthorizedException,\n type CanActivate,\n type ExecutionContext,\n} from '@aenode/nest/common';\nimport { Reflector } from '@aenode/nest/core';\nimport { type Request } from '@aenode/nest/express';\nimport { type ExtendedRequest } from '@aenode/types';\nimport { isPublic } from '../metadata/public.js';\nimport { extractBearerToken } from '../utils/index.js';\n\n/**\n * Check the target resource is public or check the user is authenciated and save the user information to the `request.user`.\n *\n */\nexport class AuthGuard implements CanActivate {\n constructor(protected readonly reflector: Reflector) {}\n async canActivate(context: ExecutionContext): Promise<boolean> {\n const req = context.switchToHttp().getRequest<ExtendedRequest & Request>();\n\n const isPublicResource = isPublic(context, this.reflector);\n\n if (isPublicResource) {\n return true;\n }\n\n const token = extractBearerToken(req);\n\n if (!token) {\n throw new UnauthorizedException('Authentication token is not provided');\n }\n\n return true;\n }\n}\n"],"names":["UnauthorizedException","isPublic","extractBearerToken","AuthGuard","reflector","canActivate","context","req","switchToHttp","getRequest","isPublicResource","token"],"mappings":"AAAA,6DAA6D,GAE7D,SACEA,qBAAqB,QAGhB,sBAAsB;AAI7B,SAASC,QAAQ,QAAQ,wBAAwB;AACjD,SAASC,kBAAkB,QAAQ,oBAAoB;AAEvD;;;CAGC,GACD,OAAO,MAAMC;IACX,YAAY,AAAmBC,SAAoB,CAAE;aAAtBA,YAAAA;IAAuB;IACtD,MAAMC,YAAYC,OAAyB,EAAoB;QAC7D,MAAMC,MAAMD,QAAQE,YAAY,GAAGC,UAAU;QAE7C,MAAMC,mBAAmBT,SAASK,SAAS,IAAI,CAACF,SAAS;QAEzD,IAAIM,kBAAkB;YACpB,OAAO;QACT;QAEA,MAAMC,QAAQT,mBAAmBK;QAEjC,IAAI,CAACI,OAAO;YACV,MAAM,IAAIX,sBAAsB;QAClC;QAEA,OAAO;IACT;AACF"}
@@ -0,0 +1,4 @@
1
+ export * from './guards/auth.guard.js';
2
+ export * from './nest-auth.js';
3
+ export * from './utils/extract-bearer-token.js';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/lib/index.ts"],"names":[],"mappings":"AACA,cAAc,wBAAwB,CAAC;AACvC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iCAAiC,CAAC"}
@@ -0,0 +1,6 @@
1
+ // @index(['./**/*.ts', '!./**/*.spec.ts','!./**/index.ts', '!./**/_*.ts','!./**/{main,bootstrap}.ts', '!./**/generated/**'], f => `export * from '${f.path}.js'`)
2
+ export * from './guards/auth.guard.js';
3
+ export * from './nest-auth.js';
4
+ export * from './utils/extract-bearer-token.js';
5
+
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/lib/index.ts"],"sourcesContent":["// @index(['./**/*.ts', '!./**/*.spec.ts','!./**/index.ts', '!./**/_*.ts','!./**/{main,bootstrap}.ts', '!./**/generated/**'], f => `export * from '${f.path}.js'`)\nexport * from './guards/auth.guard.js';\nexport * from './nest-auth.js';\nexport * from './utils/extract-bearer-token.js';\n"],"names":[],"mappings":"AAAA,kKAAkK;AAClK,cAAc,yBAAyB;AACvC,cAAc,iBAAiB;AAC/B,cAAc,kCAAkC"}
@@ -0,0 +1,2 @@
1
+ export * from './public.js';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/metadata/index.ts"],"names":[],"mappings":"AACA,cAAc,aAAa,CAAC"}
@@ -0,0 +1,4 @@
1
+ // @index(['./**/*.ts', '!./**/*.spec.ts','!./**/index.ts', '!./**/_*.ts','!./**/main.ts', '!./**/generated/**'], f => `export * from '${f.path}.js'`)
2
+ export * from './public.js';
3
+
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/metadata/index.ts"],"sourcesContent":["// @index(['./**/*.ts', '!./**/*.spec.ts','!./**/index.ts', '!./**/_*.ts','!./**/main.ts', '!./**/generated/**'], f => `export * from '${f.path}.js'`)\nexport * from './public.js';\n"],"names":[],"mappings":"AAAA,sJAAsJ;AACtJ,cAAc,cAAc"}
@@ -0,0 +1,18 @@
1
+ import { MetadataToken } from '@aenode/constants';
2
+ import { type ExecutionContext } from '@aenode/nest/common';
3
+ import type { Reflector } from '@aenode/nest/core';
4
+ /**
5
+ * Mark the target resource as public which will bypass the authentication
6
+ *
7
+ * @returns Class/Method decorator
8
+ */
9
+ export declare const Public: () => import("@aenode/nest/common").CustomDecorator<MetadataToken>;
10
+ /**
11
+ * Check the resource is marked as public or not.
12
+ *
13
+ * @param context nestjs execution context
14
+ * @param reflector nestjs core Reflector
15
+ * @returns boolean
16
+ */
17
+ export declare function isPublic(context: ExecutionContext, reflector: Reflector): boolean;
18
+ //# sourceMappingURL=public.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"public.d.ts","sourceRoot":"","sources":["../../../src/lib/metadata/public.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,EAAe,KAAK,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACzE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEnD;;;;GAIG;AACH,eAAO,MAAM,MAAM,oEAAgD,CAAC;AAEpE;;;;;;GAMG;AACH,wBAAgB,QAAQ,CACtB,OAAO,EAAE,gBAAgB,EACzB,SAAS,EAAE,SAAS,GACnB,OAAO,CAKT"}
@@ -0,0 +1,21 @@
1
+ import { MetadataToken } from '@aenode/constants';
2
+ import { SetMetadata } from '@aenode/nest/common';
3
+ /**
4
+ * Mark the target resource as public which will bypass the authentication
5
+ *
6
+ * @returns Class/Method decorator
7
+ */ export const Public = ()=>SetMetadata(MetadataToken.PUBLIC, true);
8
+ /**
9
+ * Check the resource is marked as public or not.
10
+ *
11
+ * @param context nestjs execution context
12
+ * @param reflector nestjs core Reflector
13
+ * @returns boolean
14
+ */ export function isPublic(context, reflector) {
15
+ return !!reflector.getAllAndOverride(MetadataToken.PUBLIC, [
16
+ context.getHandler(),
17
+ context.getClass()
18
+ ]);
19
+ }
20
+
21
+ //# sourceMappingURL=public.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/metadata/public.ts"],"sourcesContent":["import { MetadataToken } from '@aenode/constants';\nimport { SetMetadata, type ExecutionContext } from '@aenode/nest/common';\nimport type { Reflector } from '@aenode/nest/core';\n\n/**\n * Mark the target resource as public which will bypass the authentication\n *\n * @returns Class/Method decorator\n */\nexport const Public = () => SetMetadata(MetadataToken.PUBLIC, true);\n\n/**\n * Check the resource is marked as public or not.\n *\n * @param context nestjs execution context\n * @param reflector nestjs core Reflector\n * @returns boolean\n */\nexport function isPublic(\n context: ExecutionContext,\n reflector: Reflector,\n): boolean {\n return !!reflector.getAllAndOverride<boolean | undefined>(\n MetadataToken.PUBLIC,\n [context.getHandler(), context.getClass()],\n );\n}\n"],"names":["MetadataToken","SetMetadata","Public","PUBLIC","isPublic","context","reflector","getAllAndOverride","getHandler","getClass"],"mappings":"AAAA,SAASA,aAAa,QAAQ,oBAAoB;AAClD,SAASC,WAAW,QAA+B,sBAAsB;AAGzE;;;;CAIC,GACD,OAAO,MAAMC,SAAS,IAAMD,YAAYD,cAAcG,MAAM,EAAE,MAAM;AAEpE;;;;;;CAMC,GACD,OAAO,SAASC,SACdC,OAAyB,EACzBC,SAAoB;IAEpB,OAAO,CAAC,CAACA,UAAUC,iBAAiB,CAClCP,cAAcG,MAAM,EACpB;QAACE,QAAQG,UAAU;QAAIH,QAAQI,QAAQ;KAAG;AAE9C"}
@@ -0,0 +1,2 @@
1
+ export declare function nestAuth(): string;
2
+ //# sourceMappingURL=nest-auth.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"nest-auth.d.ts","sourceRoot":"","sources":["../../src/lib/nest-auth.ts"],"names":[],"mappings":"AAAA,wBAAgB,QAAQ,WAEvB"}
@@ -0,0 +1,5 @@
1
+ export function nestAuth() {
2
+ return 'nest-auth';
3
+ }
4
+
5
+ //# sourceMappingURL=nest-auth.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/lib/nest-auth.ts"],"sourcesContent":["export function nestAuth() {\n return 'nest-auth';\n}\n"],"names":["nestAuth"],"mappings":"AAAA,OAAO,SAASA;IACd,OAAO;AACT"}
@@ -0,0 +1,10 @@
1
+ import type { Request } from '@aenode/nest/express';
2
+ import type { ExtendedRequest } from '@aenode/types';
3
+ /**
4
+ * Extract the bearer token from the authorization header, validate, and return.
5
+ *
6
+ * @param request Express request
7
+ * @returns authentication token
8
+ */
9
+ export declare function extractBearerToken(request: ExtendedRequest & Request): string;
10
+ //# sourceMappingURL=extract-bearer-token.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"extract-bearer-token.d.ts","sourceRoot":"","sources":["../../../src/lib/utils/extract-bearer-token.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAErD;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,eAAe,GAAG,OAAO,UAcpE"}
@@ -0,0 +1,19 @@
1
+ import { UnauthorizedException } from '@aenode/nest/common';
2
+ /**
3
+ * Extract the bearer token from the authorization header, validate, and return.
4
+ *
5
+ * @param request Express request
6
+ * @returns authentication token
7
+ */ export function extractBearerToken(request) {
8
+ const bearerRaw = request.headers.authorization;
9
+ if (!bearerRaw) {
10
+ throw new UnauthorizedException('Bearer token is not provided');
11
+ }
12
+ const [type, token] = bearerRaw.split(' ');
13
+ if (type !== 'Bearer' || !token) {
14
+ throw new UnauthorizedException('Invalid bearer format');
15
+ }
16
+ return token;
17
+ }
18
+
19
+ //# sourceMappingURL=extract-bearer-token.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/utils/extract-bearer-token.ts"],"sourcesContent":["import { UnauthorizedException } from '@aenode/nest/common';\nimport type { Request } from '@aenode/nest/express';\nimport type { ExtendedRequest } from '@aenode/types';\n\n/**\n * Extract the bearer token from the authorization header, validate, and return.\n *\n * @param request Express request\n * @returns authentication token\n */\nexport function extractBearerToken(request: ExtendedRequest & Request) {\n const bearerRaw = request.headers.authorization;\n\n if (!bearerRaw) {\n throw new UnauthorizedException('Bearer token is not provided');\n }\n\n const [type, token] = bearerRaw.split(' ');\n\n if (type !== 'Bearer' || !token) {\n throw new UnauthorizedException('Invalid bearer format');\n }\n\n return token;\n}\n"],"names":["UnauthorizedException","extractBearerToken","request","bearerRaw","headers","authorization","type","token","split"],"mappings":"AAAA,SAASA,qBAAqB,QAAQ,sBAAsB;AAI5D;;;;;CAKC,GACD,OAAO,SAASC,mBAAmBC,OAAkC;IACnE,MAAMC,YAAYD,QAAQE,OAAO,CAACC,aAAa;IAE/C,IAAI,CAACF,WAAW;QACd,MAAM,IAAIH,sBAAsB;IAClC;IAEA,MAAM,CAACM,MAAMC,MAAM,GAAGJ,UAAUK,KAAK,CAAC;IAEtC,IAAIF,SAAS,YAAY,CAACC,OAAO;QAC/B,MAAM,IAAIP,sBAAsB;IAClC;IAEA,OAAOO;AACT"}
@@ -0,0 +1,2 @@
1
+ export * from './extract-bearer-token.js';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/utils/index.ts"],"names":[],"mappings":"AACA,cAAc,2BAA2B,CAAC"}
@@ -0,0 +1,4 @@
1
+ // @index(['./**/*.ts', '!./**/*.spec.ts','!./**/index.ts', '!./**/_*.ts','!./**/main.ts', '!./**/generated/**'], f => `export * from '${f.path}.js'`)
2
+ export * from './extract-bearer-token.js';
3
+
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/lib/utils/index.ts"],"sourcesContent":["// @index(['./**/*.ts', '!./**/*.spec.ts','!./**/index.ts', '!./**/_*.ts','!./**/main.ts', '!./**/generated/**'], f => `export * from '${f.path}.js'`)\nexport * from './extract-bearer-token.js';\n"],"names":[],"mappings":"AAAA,sJAAsJ;AACtJ,cAAc,4BAA4B"}
package/dist/main.d.ts ADDED
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=main.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../src/main.ts"],"names":[],"mappings":""}
package/dist/main.js ADDED
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env node
2
+ console.log(`Hello from @aenode/nest-auth`);
3
+
4
+ //# sourceMappingURL=main.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/main.ts"],"sourcesContent":["#!/usr/bin/env node\n\nconsole.log(`Hello from @aenode/nest-auth`);\n"],"names":["console","log"],"mappings":";AAEAA,QAAQC,GAAG,CAAC,CAAC,4BAA4B,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,65 @@
1
1
  {
2
2
  "name": "@aenode/nest-auth",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.0.36",
4
+ "description": "Nest auth module",
5
+ "author": {
6
+ "name": "Ahmet Emrebas",
7
+ "email": "aenode+aenode+aenode-nest-auth@proton.me",
8
+ "url": "https://aenode.github.io/#profile"
9
+ },
10
+ "bin": {
11
+ "aenode-nest-auth": "./bin/nest-auth.mjs"
12
+ },
13
+ "funding": "https://cash.app/$puqlib",
14
+ "homepage": "https://aenode.github.io/aenode/libs/nest-auth",
15
+ "repository": {
16
+ "directory": "libs/nest-auth",
17
+ "type": "github",
18
+ "url": "https://github.com/aenode/aenode/tree/main/libs/nest-auth"
19
+ },
20
+ "icon": "https://aenode.github.io/aenode/libs/nest-auth/assets/favicon.svg",
21
+ "keywords": [
22
+ "lib"
23
+ ],
24
+ "publishConfig": {
25
+ "access": "public",
26
+ "tag": "latest"
27
+ },
28
+ "type": "module",
29
+ "main": "./dist/index.js",
30
+ "module": "./dist/index.js",
31
+ "types": "./dist/index.d.ts",
32
+ "exports": {
33
+ "./package.json": "./package.json",
34
+ ".": {
35
+ "bun": "./src/index.ts",
36
+ "types": "./dist/index.d.ts",
37
+ "import": "./dist/index.js",
38
+ "default": "./dist/index.js"
39
+ }
40
+ },
41
+ "files": [
42
+ "assets",
43
+ "bin",
44
+ "dist",
45
+ "generators.json",
46
+ "!**/*.tsbuildinfo"
47
+ ],
48
+ "nx": {
49
+ "sourceRoot": "libs/nest-auth/src",
50
+ "projectType": "library",
51
+ "tags": [
52
+ "lib:module"
53
+ ],
54
+ "targets": {
55
+ "build": {},
56
+ "doc": {}
57
+ }
58
+ },
59
+ "dependencies": {
60
+ "@aenode/constants": "workspace:*",
61
+ "@aenode/nest": "workspace:*",
62
+ "@swc/helpers": "~0.5.18",
63
+ "@aenode/types": "workspace:*"
64
+ }
65
+ }