@forinda/kickjs 3.1.3 → 3.2.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/{adapter-DjL8ql5d.d.mts → adapter-DLEHb0K6.d.mts} +14 -3
- package/dist/adapter-DLEHb0K6.d.mts.map +1 -0
- package/dist/{app-module-Cotu9TIC.d.mts → app-module-ERR9jhow.d.mts} +12 -2
- package/dist/app-module-ERR9jhow.d.mts.map +1 -0
- package/dist/{application-BVl6L8xo.mjs → application-x8CXLOlv.mjs} +92 -22
- package/dist/application-x8CXLOlv.mjs.map +1 -0
- package/dist/{bootstrap-D6leYXz2.mjs → bootstrap-CYnxozL_.mjs} +6 -6
- package/dist/{bootstrap-D6leYXz2.mjs.map → bootstrap-CYnxozL_.mjs.map} +1 -1
- package/dist/{cache-CcTzzNdr.d.mts → cache-V91BNTIM.d.mts} +1 -1
- package/dist/{cache-CcTzzNdr.d.mts.map → cache-V91BNTIM.d.mts.map} +1 -1
- package/dist/{chunk-CVPG7JJl.mjs → chunk-Bt-rz0Tp.mjs} +1 -1
- package/dist/config/index.d.mts +1 -1
- package/dist/config/index.mjs +3 -3
- package/dist/{config-gkVEnxVm.mjs → config-aWxKLk4A.mjs} +3 -3
- package/dist/{config-gkVEnxVm.mjs.map → config-aWxKLk4A.mjs.map} +1 -1
- package/dist/{container-BBZLlK6y.mjs → container-Dnk43k54.mjs} +3 -3
- package/dist/{container-BBZLlK6y.mjs.map → container-Dnk43k54.mjs.map} +1 -1
- package/dist/{container-BJb34faa.d.mts → container-fIS1uLx-.d.mts} +2 -2
- package/dist/{container-BJb34faa.d.mts.map → container-fIS1uLx-.d.mts.map} +1 -1
- package/dist/context-OktlOQBQ.mjs +327 -0
- package/dist/context-OktlOQBQ.mjs.map +1 -0
- package/dist/context-decorator-GA8-hDLe.d.mts +111 -0
- package/dist/context-decorator-GA8-hDLe.d.mts.map +1 -0
- package/dist/core/adapter.d.mts +1 -1
- package/dist/core/adapter.mjs +1 -1
- package/dist/core/app-module.d.mts +1 -1
- package/dist/core/app-module.mjs +1 -1
- package/dist/core/cache.d.mts +1 -1
- package/dist/core/cache.mjs +1 -1
- package/dist/core/container.d.mts +1 -1
- package/dist/core/container.mjs +2 -2
- package/dist/core/cron.d.mts +1 -1
- package/dist/core/cron.mjs +2 -2
- package/dist/core/decorators.d.mts +1 -1
- package/dist/core/decorators.mjs +3 -3
- package/dist/core/errors.d.mts +1 -1
- package/dist/core/errors.mjs +1 -1
- package/dist/core/interfaces.d.mts +1 -1
- package/dist/core/interfaces.mjs +3 -1
- package/dist/core/interfaces.mjs.map +1 -1
- package/dist/core/logger.d.mts +1 -1
- package/dist/core/logger.mjs +1 -1
- package/dist/core/path.d.mts +1 -1
- package/dist/core/path.mjs +1 -1
- package/dist/core/plugin.d.mts +1 -1
- package/dist/core/plugin.mjs +1 -1
- package/dist/core/reactivity.d.mts +1 -1
- package/dist/core/reactivity.mjs +1 -1
- package/dist/core-DANnH5-e.mjs +435 -0
- package/dist/core-DANnH5-e.mjs.map +1 -0
- package/dist/{cron-H-IyLcOr.d.mts → cron-CfsPdi7R.d.mts} +1 -1
- package/dist/{cron-H-IyLcOr.d.mts.map → cron-CfsPdi7R.d.mts.map} +1 -1
- package/dist/{decorators-C9_SN7ge.d.mts → decorators-H42oPg0m.d.mts} +2 -2
- package/dist/{decorators-C9_SN7ge.d.mts.map → decorators-H42oPg0m.d.mts.map} +1 -1
- package/dist/{env-Cu5hWsuE.mjs → env-Cs8Wt8A_.mjs} +4 -4
- package/dist/{env-Cu5hWsuE.mjs.map → env-Cs8Wt8A_.mjs.map} +1 -1
- package/dist/{errors-BOUCRl-p.d.mts → errors-D_CWI7Bl.d.mts} +1 -1
- package/dist/{errors-BOUCRl-p.d.mts.map → errors-D_CWI7Bl.d.mts.map} +1 -1
- package/dist/execution-context-Dl2CKqSo.d.mts +57 -0
- package/dist/execution-context-Dl2CKqSo.d.mts.map +1 -0
- package/dist/http/application.d.mts +60 -6
- package/dist/http/application.d.mts.map +1 -1
- package/dist/http/application.mjs +2 -2
- package/dist/http/bootstrap.mjs +2 -2
- package/dist/http/context.d.mts +21 -32
- package/dist/http/context.d.mts.map +1 -1
- package/dist/http/context.mjs +2 -271
- package/dist/http/middleware/cors.mjs +1 -1
- package/dist/http/middleware/csrf.mjs +1 -1
- package/dist/http/middleware/error-handler.mjs +2 -2
- package/dist/http/middleware/helmet.mjs +1 -1
- package/dist/http/middleware/rate-limit.mjs +1 -1
- package/dist/http/middleware/request-id.mjs +1 -1
- package/dist/http/middleware/request-logger.mjs +2 -2
- package/dist/http/middleware/session.mjs +1 -1
- package/dist/http/middleware/spa.d.mts +1 -1
- package/dist/http/middleware/spa.mjs +3 -3
- package/dist/http/middleware/upload.d.mts +1 -1
- package/dist/http/middleware/upload.mjs +1 -1
- package/dist/http/middleware/validate.mjs +2 -2
- package/dist/http/middleware/views.d.mts +1 -1
- package/dist/http/middleware/views.mjs +2 -2
- package/dist/http/query/index.d.mts +1 -1
- package/dist/http/query/index.mjs +2 -2
- package/dist/http/router-builder.d.mts +14 -2
- package/dist/http/router-builder.d.mts.map +1 -1
- package/dist/http/router-builder.mjs +59 -7
- package/dist/http/router-builder.mjs.map +1 -1
- package/dist/index-BQM9pJrV.d.mts +275 -0
- package/dist/index-BQM9pJrV.d.mts.map +1 -0
- package/dist/{index-DNVfGjF9.d.mts → index-Cf-MGrqT.d.mts} +2 -2
- package/dist/{index-DNVfGjF9.d.mts.map → index-Cf-MGrqT.d.mts.map} +1 -1
- package/dist/{index-Co7a3Zat.d.mts → index-RNK41JPE.d.mts} +1 -1
- package/dist/{index-Co7a3Zat.d.mts.map → index-RNK41JPE.d.mts.map} +1 -1
- package/dist/index.d.mts +38 -19
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +11 -11
- package/dist/{interfaces-DXjE8Re1.d.mts → interfaces-CwcdqfNq.d.mts} +3 -1
- package/dist/{interfaces-DXjE8Re1.d.mts.map → interfaces-CwcdqfNq.d.mts.map} +1 -1
- package/dist/{logger-CW6FHtvU.d.mts → logger-GK8yT0BD.d.mts} +1 -1
- package/dist/{logger-CW6FHtvU.d.mts.map → logger-GK8yT0BD.d.mts.map} +1 -1
- package/dist/{metadata-BwRJ69bC.mjs → metadata-BFuoSEX6.mjs} +2 -2
- package/dist/{metadata-BwRJ69bC.mjs.map → metadata-BFuoSEX6.mjs.map} +1 -1
- package/dist/{path-B4JcbwKX.d.mts → path-Bj3vZMUY.d.mts} +1 -1
- package/dist/path-Bj3vZMUY.d.mts.map +1 -0
- package/dist/{plugin-Cvacmm7N.d.mts → plugin-3rKA0Loy.d.mts} +36 -4
- package/dist/plugin-3rKA0Loy.d.mts.map +1 -0
- package/dist/{query-BQ2UT3oi.mjs → query-BcYEjYyX.mjs} +2 -2
- package/dist/{query-BQ2UT3oi.mjs.map → query-BcYEjYyX.mjs.map} +1 -1
- package/dist/{reactivity-I8nDlg4c.d.mts → reactivity-CczHu3R-.d.mts} +1 -1
- package/dist/{reactivity-I8nDlg4c.d.mts.map → reactivity-CczHu3R-.d.mts.map} +1 -1
- package/package.json +1 -1
- package/dist/adapter-DjL8ql5d.d.mts.map +0 -1
- package/dist/app-module-Cotu9TIC.d.mts.map +0 -1
- package/dist/application-BVl6L8xo.mjs.map +0 -1
- package/dist/core-qyPNtpKp.mjs +0 -121
- package/dist/core-qyPNtpKp.mjs.map +0 -1
- package/dist/http/context.mjs.map +0 -1
- package/dist/index-CwqjAF6I.d.mts +0 -112
- package/dist/index-CwqjAF6I.d.mts.map +0 -1
- package/dist/path-B4JcbwKX.d.mts.map +0 -1
- package/dist/plugin-Cvacmm7N.d.mts.map +0 -1
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
|
|
2
|
+
import { i as Constructor, o as MaybePromise } from "./interfaces-CwcdqfNq.mjs";
|
|
3
|
+
import { s as InjectionToken } from "./container-fIS1uLx-.mjs";
|
|
4
|
+
import { n as ExecutionContext, r as MetaValue } from "./execution-context-Dl2CKqSo.mjs";
|
|
5
|
+
//#region src/core/context-decorator.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Maps a `deps` declaration object to its resolved-instance shape.
|
|
8
|
+
*
|
|
9
|
+
* `deps: { db: DB_TOKEN, cache: CacheService }` produces
|
|
10
|
+
* `{ db: Db, cache: CacheService }` — the runner resolves each value
|
|
11
|
+
* against the DI container and hands the result to `resolve()`.
|
|
12
|
+
*/
|
|
13
|
+
type ResolvedDeps<D extends Record<string, unknown>> = { [K in keyof D]: D[K] extends InjectionToken<infer T> ? T : D[K] extends Constructor<infer T> ? T : unknown };
|
|
14
|
+
/**
|
|
15
|
+
* Spec passed to {@link defineContextDecorator}. Describes one entry in
|
|
16
|
+
* the per-request contributor pipeline.
|
|
17
|
+
*
|
|
18
|
+
* @typeParam K - The {@link ContextMeta} key this contributor populates.
|
|
19
|
+
* @typeParam D - DI dependency declaration shape (see {@link ResolvedDeps}).
|
|
20
|
+
* @typeParam Ctx - Concrete execution-context type. Defaults to the abstract
|
|
21
|
+
* {@link ExecutionContext}; HTTP contributors typically
|
|
22
|
+
* default to `RequestContext` at the call site.
|
|
23
|
+
*/
|
|
24
|
+
interface ContextDecoratorSpec<K extends string = string, D extends Record<string, unknown> = Record<string, never>, Ctx extends ExecutionContext = ExecutionContext> {
|
|
25
|
+
/** ContextMeta key the resolved value is written to. */
|
|
26
|
+
key: K;
|
|
27
|
+
/**
|
|
28
|
+
* DI dependencies resolved by the runner before `resolve()` runs.
|
|
29
|
+
* Map entry keys become property names on the resolved-deps argument
|
|
30
|
+
* passed to `resolve()`.
|
|
31
|
+
*/
|
|
32
|
+
deps?: D;
|
|
33
|
+
/**
|
|
34
|
+
* Other contributor keys that must populate before this one runs.
|
|
35
|
+
* Enforced via topo-sort at startup; missing deps and cycles fail boot.
|
|
36
|
+
*/
|
|
37
|
+
dependsOn?: readonly string[];
|
|
38
|
+
/**
|
|
39
|
+
* If `true`, a thrown `resolve` skips the contributor instead of
|
|
40
|
+
* forwarding to the request error handler. The key is left unset
|
|
41
|
+
* and downstream consumers see `ctx.get(key) === undefined`.
|
|
42
|
+
*/
|
|
43
|
+
optional?: boolean;
|
|
44
|
+
/**
|
|
45
|
+
* Hook invoked when `resolve()` throws and `optional` is `false`.
|
|
46
|
+
* Returning a value writes it to `ctx.set(key, …)`; returning
|
|
47
|
+
* `undefined` / `void` skips. Throwing inside the hook forwards
|
|
48
|
+
* the new error to the request error handler.
|
|
49
|
+
*
|
|
50
|
+
* Async-permitted by design — adopters frequently want to
|
|
51
|
+
* `await auditService.log(err)` or `await cache.fallback(...)`.
|
|
52
|
+
*/
|
|
53
|
+
onError?: (err: unknown, ctx: Ctx) => MaybePromise<MetaValue<K> | undefined | void>;
|
|
54
|
+
/** Compute and return the value to write into `ctx.set(key, …)`. */
|
|
55
|
+
resolve: (ctx: Ctx, deps: ResolvedDeps<D>) => MaybePromise<MetaValue<K>>;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Internal, normalised registration produced by {@link defineContextDecorator}.
|
|
59
|
+
*
|
|
60
|
+
* Frozen and shared by every use site of the decorator (method, class,
|
|
61
|
+
* module, adapter, global). The pipeline builder dedupes by `key` using
|
|
62
|
+
* the precedence rule defined in §20.4 of `architecture.md`.
|
|
63
|
+
*/
|
|
64
|
+
interface ContributorRegistration<K extends string = string, D extends Record<string, unknown> = Record<string, never>, Ctx extends ExecutionContext = ExecutionContext> {
|
|
65
|
+
readonly key: K;
|
|
66
|
+
readonly deps: D;
|
|
67
|
+
readonly dependsOn: readonly string[];
|
|
68
|
+
readonly optional: boolean;
|
|
69
|
+
readonly onError?: ContextDecoratorSpec<K, D, Ctx>['onError'];
|
|
70
|
+
readonly resolve: ContextDecoratorSpec<K, D, Ctx>['resolve'];
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* The value returned by {@link defineContextDecorator}. Callable as either
|
|
74
|
+
* a method or class decorator, and exposes the underlying frozen
|
|
75
|
+
* {@link ContributorRegistration} via `.registration` for non-decorator
|
|
76
|
+
* registration sites (module hooks, adapter hooks, bootstrap option).
|
|
77
|
+
*/
|
|
78
|
+
interface ContextDecorator<K extends string = string, D extends Record<string, unknown> = Record<string, never>, Ctx extends ExecutionContext = ExecutionContext> {
|
|
79
|
+
(target: object, propertyKey?: string | symbol, descriptor?: PropertyDescriptor): void;
|
|
80
|
+
readonly registration: ContributorRegistration<K, D, Ctx>;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Define a typed context contributor.
|
|
84
|
+
*
|
|
85
|
+
* The returned function works as a method or class decorator:
|
|
86
|
+
*
|
|
87
|
+
* ```ts
|
|
88
|
+
* const LoadTenant = defineContextDecorator({
|
|
89
|
+
* key: 'tenant',
|
|
90
|
+
* deps: { tenants: TenantsRepo },
|
|
91
|
+
* resolve: (ctx, { tenants }) => tenants.findByHost(ctx.requestId),
|
|
92
|
+
* })
|
|
93
|
+
*
|
|
94
|
+
* @LoadTenant
|
|
95
|
+
* @Get('/me')
|
|
96
|
+
* me(ctx: RequestContext) {
|
|
97
|
+
* ctx.get('tenant') // typed via ContextMeta
|
|
98
|
+
* }
|
|
99
|
+
* ```
|
|
100
|
+
*
|
|
101
|
+
* For non-decorator registration (module/adapter/bootstrap), pass
|
|
102
|
+
* `LoadTenant.registration` into the appropriate contributors list.
|
|
103
|
+
*
|
|
104
|
+
* **No runtime behaviour is wired in Phase 1.** This factory only writes
|
|
105
|
+
* metadata; the topo-sort, runner, and HTTP integration land in later
|
|
106
|
+
* phases. See `architecture.md` §20 for the full pipeline plan.
|
|
107
|
+
*/
|
|
108
|
+
declare function defineContextDecorator<K extends string, D extends Record<string, unknown> = Record<string, never>, Ctx extends ExecutionContext = ExecutionContext>(spec: ContextDecoratorSpec<K, D, Ctx>): ContextDecorator<K, D, Ctx>;
|
|
109
|
+
//#endregion
|
|
110
|
+
export { defineContextDecorator as a, ResolvedDeps as i, ContextDecoratorSpec as n, ContributorRegistration as r, ContextDecorator as t };
|
|
111
|
+
//# sourceMappingURL=context-decorator-GA8-hDLe.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"context-decorator-GA8-hDLe.d.mts","names":[],"sources":["../src/core/context-decorator.ts"],"mappings":";;;;;;;AAaA;;;;;KAAY,YAAA,WAAuB,MAAA,mCACrB,CAAA,GAAI,CAAA,CAAE,CAAA,UAAW,cAAA,YACzB,CAAA,GACA,CAAA,CAAE,CAAA,UAAW,WAAA,YACX,CAAA;;;;;;;;;;;UAcS,oBAAA,sCAEL,MAAA,oBAA0B,MAAA,6BACxB,gBAAA,GAAmB,gBAAA;EApBF;EAuB7B,GAAA,EAAK,CAAA;EAtBD;;;;;EA4BJ,IAAA,GAAO,CAAA;EA1BA;;AAcT;;EAiBE,SAAA;EAfU;;;;;EAqBV,QAAA;EAU8B;;;;;;;;;EAA9B,OAAA,IAAW,GAAA,WAAc,GAAA,EAAK,GAAA,KAAQ,YAAA,CAAa,SAAA,CAAU,CAAA;EAEH;EAA1D,OAAA,GAAU,GAAA,EAAK,GAAA,EAAK,IAAA,EAAM,YAAA,CAAa,CAAA,MAAO,YAAA,CAAa,SAAA,CAAU,CAAA;AAAA;;;;;;;;UAUtD,uBAAA,sCAEL,MAAA,oBAA0B,MAAA,6BACxB,gBAAA,GAAmB,gBAAA;EAAA,SAEtB,GAAA,EAAK,CAAA;EAAA,SACL,IAAA,EAAM,CAAA;EAAA,SACN,SAAA;EAAA,SACA,QAAA;EAAA,SACA,OAAA,GAAU,oBAAA,CAAqB,CAAA,EAAG,CAAA,EAAG,GAAA;EAAA,SACrC,OAAA,EAAS,oBAAA,CAAqB,CAAA,EAAG,CAAA,EAAG,GAAA;AAAA;;;;;;;UAS9B,gBAAA,sCAEL,MAAA,oBAA0B,MAAA,6BACxB,gBAAA,GAAmB,gBAAA;EAAA,CAE9B,MAAA,UAAgB,WAAA,oBAA+B,UAAA,GAAa,kBAAA;EAAA,SACpD,YAAA,EAAc,uBAAA,CAAwB,CAAA,EAAG,CAAA,EAAG,GAAA;AAAA;;;;;;AAzBvD;;;;;;;;;;;;;;;;;;;;;iBAsDgB,sBAAA,6BAEJ,MAAA,oBAA0B,MAAA,6BACxB,gBAAA,GAAmB,gBAAA,CAAA,CAC/B,IAAA,EAAM,oBAAA,CAAqB,CAAA,EAAG,CAAA,EAAG,GAAA,IAAO,gBAAA,CAAiB,CAAA,EAAG,CAAA,EAAG,GAAA"}
|
package/dist/core/adapter.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { a as MiddlewarePhase, i as AppAdapterClass, n as AdapterMiddleware, r as AppAdapter, t as AdapterContext } from "../adapter-
|
|
2
|
+
import { a as MiddlewarePhase, i as AppAdapterClass, n as AdapterMiddleware, r as AppAdapter, t as AdapterContext } from "../adapter-DLEHb0K6.mjs";
|
|
3
3
|
export { AdapterContext, AdapterMiddleware, AppAdapter, AppAdapterClass, MiddlewarePhase };
|
package/dist/core/adapter.mjs
CHANGED
package/dist/core/app-module.mjs
CHANGED
package/dist/core/cache.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { a as Cacheable, c as setCacheProvider, i as CacheProvider, n as CacheEvict, o as MemoryCacheProvider, r as CacheOptions, s as getCacheProvider, t as CACHEABLE_META } from "../cache-
|
|
2
|
+
import { a as Cacheable, c as setCacheProvider, i as CacheProvider, n as CacheEvict, o as MemoryCacheProvider, r as CacheOptions, s as getCacheProvider, t as CACHEABLE_META } from "../cache-V91BNTIM.mjs";
|
|
3
3
|
export { CACHEABLE_META, CacheEvict, CacheOptions, CacheProvider, Cacheable, MemoryCacheProvider, getCacheProvider, setCacheProvider };
|
package/dist/core/cache.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { a as tokenName, i as KickJsRegistry, n as ContainerChangeEvent, r as ContainerChangeListener, t as Container } from "../container-
|
|
2
|
+
import { a as tokenName, i as KickJsRegistry, n as ContainerChangeEvent, r as ContainerChangeListener, t as Container } from "../container-fIS1uLx-.mjs";
|
|
3
3
|
export { Container, ContainerChangeEvent, ContainerChangeListener, KickJsRegistry, tokenName };
|
package/dist/core/container.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @forinda/kickjs v3.
|
|
2
|
+
* @forinda/kickjs v3.2.0
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Felix Orinda
|
|
5
5
|
*
|
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
*
|
|
9
9
|
* @license MIT
|
|
10
10
|
*/
|
|
11
|
-
import { n as tokenName, t as Container } from "../container-
|
|
11
|
+
import { n as tokenName, t as Container } from "../container-Dnk43k54.mjs";
|
|
12
12
|
export { Container, tokenName };
|
package/dist/core/cron.d.mts
CHANGED
package/dist/core/cron.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @forinda/kickjs v3.
|
|
2
|
+
* @forinda/kickjs v3.2.0
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Felix Orinda
|
|
5
5
|
*
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*
|
|
9
9
|
* @license MIT
|
|
10
10
|
*/
|
|
11
|
-
import { c as pushClassMeta, t as getClassMeta } from "../metadata-
|
|
11
|
+
import { c as pushClassMeta, t as getClassMeta } from "../metadata-BFuoSEX6.mjs";
|
|
12
12
|
//#region src/core/cron.ts
|
|
13
13
|
const CRON_META = Symbol("kick:cron");
|
|
14
14
|
/**
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { C as Put, D as Value, E as Service, O as normalizeApiQueryParamsConfig, S as PostConstruct, T as RouteDefinition, _ as Injectable, a as Builder, b as Patch, c as Controller, d as EnvKey, f as FileTypeFilter, g as Inject, h as Get, i as BaseUploadOptions, l as Delete, m as FileUploadConfig, n as ApiQueryParamsConfig, o as ColumnApiQueryParamsConfig, p as FileUpload, r as Autowired, s as Component, t as ApiQueryParams, u as Env, v as Middleware, w as Repository, x as Post, y as MiddlewareHandler } from "../decorators-
|
|
2
|
+
import { C as Put, D as Value, E as Service, O as normalizeApiQueryParamsConfig, S as PostConstruct, T as RouteDefinition, _ as Injectable, a as Builder, b as Patch, c as Controller, d as EnvKey, f as FileTypeFilter, g as Inject, h as Get, i as BaseUploadOptions, l as Delete, m as FileUploadConfig, n as ApiQueryParamsConfig, o as ColumnApiQueryParamsConfig, p as FileUpload, r as Autowired, s as Component, t as ApiQueryParams, u as Env, v as Middleware, w as Repository, x as Post, y as MiddlewareHandler } from "../decorators-H42oPg0m.mjs";
|
|
3
3
|
export { ApiQueryParams, ApiQueryParamsConfig, Autowired, BaseUploadOptions, Builder, ColumnApiQueryParamsConfig, Component, Controller, Delete, Env, EnvKey, FileTypeFilter, FileUpload, FileUploadConfig, Get, Inject, Injectable, Middleware, MiddlewareHandler, Patch, Post, PostConstruct, Put, Repository, RouteDefinition, Service, Value, normalizeApiQueryParamsConfig };
|
package/dist/core/decorators.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @forinda/kickjs v3.
|
|
2
|
+
* @forinda/kickjs v3.2.0
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Felix Orinda
|
|
5
5
|
*
|
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
* @license MIT
|
|
10
10
|
*/
|
|
11
11
|
import { METADATA, Scope } from "./interfaces.mjs";
|
|
12
|
-
import { c as pushClassMeta, d as setInMetaMap, f as setInMetaRecord, l as pushMethodMeta, p as setMethodMeta, u as setClassMeta } from "../metadata-
|
|
13
|
-
import { t as Container } from "../container-
|
|
12
|
+
import { c as pushClassMeta, d as setInMetaMap, f as setInMetaRecord, l as pushMethodMeta, p as setMethodMeta, u as setClassMeta } from "../metadata-BFuoSEX6.mjs";
|
|
13
|
+
import { t as Container } from "../container-Dnk43k54.mjs";
|
|
14
14
|
import "reflect-metadata";
|
|
15
15
|
//#region src/core/decorators.ts
|
|
16
16
|
const pendingRegistrations = [];
|
package/dist/core/errors.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { i as ValidationError, n as HttpStatus, r as HttpStatusCode, t as HttpException } from "../errors-
|
|
2
|
+
import { i as ValidationError, n as HttpStatus, r as HttpStatusCode, t as HttpException } from "../errors-D_CWI7Bl.mjs";
|
|
3
3
|
export { HttpException, HttpStatus, HttpStatusCode, ValidationError };
|
package/dist/core/errors.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { a as METADATA, c as Scope, i as Constructor, l as ServiceOptions, n as BuilderOf, o as MaybePromise, r as ClassKind, s as PostConstructStatus, t as Buildable } from "../interfaces-
|
|
2
|
+
import { a as METADATA, c as Scope, i as Constructor, l as ServiceOptions, n as BuilderOf, o as MaybePromise, r as ClassKind, s as PostConstructStatus, t as Buildable } from "../interfaces-CwcdqfNq.mjs";
|
|
3
3
|
export { Buildable, BuilderOf, ClassKind, Constructor, METADATA, MaybePromise, PostConstructStatus, Scope, ServiceOptions };
|
package/dist/core/interfaces.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @forinda/kickjs v3.
|
|
2
|
+
* @forinda/kickjs v3.2.0
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Felix Orinda
|
|
5
5
|
*
|
|
@@ -32,6 +32,8 @@ const METADATA = {
|
|
|
32
32
|
ROUTES: Symbol("kick:routes"),
|
|
33
33
|
CLASS_MIDDLEWARES: Symbol("kick:class:middlewares"),
|
|
34
34
|
METHOD_MIDDLEWARES: Symbol("kick:method:middlewares"),
|
|
35
|
+
CLASS_CONTRIBUTORS: Symbol("kick:class:contributors"),
|
|
36
|
+
METHOD_CONTRIBUTORS: Symbol("kick:method:contributors"),
|
|
35
37
|
FILE_UPLOAD: Symbol("kick:file:upload"),
|
|
36
38
|
VALUE: Symbol("kick:value"),
|
|
37
39
|
PARAM_TYPES: "design:paramtypes",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interfaces.mjs","names":[],"sources":["../../src/core/interfaces.ts"],"sourcesContent":["import 'reflect-metadata'\n\n/** Lifecycle scope for DI registrations */\nexport enum Scope {\n SINGLETON = 'singleton',\n TRANSIENT = 'transient',\n /** One instance per HTTP request, cached in AsyncLocalStorage. Throws outside request context. */\n REQUEST = 'request',\n}\n\n/** Generic constructor type */\nexport type Constructor<T = any> = new (...args: any[]) => T\n\n/** A value that may or may not be wrapped in a Promise */\nexport type MaybePromise<T = void> = T | Promise<T>\n\n/** Options for @Service, @Repository, @Component decorators */\nexport interface ServiceOptions {\n scope?: Scope\n}\n\n/** Fluent builder type */\nexport type BuilderOf<T> = {\n [K in keyof T as T[K] extends Function ? never : K]-?: (value: T[K]) => BuilderOf<T>\n} & { build(): T }\n\n/** Class with static builder() method */\nexport interface Buildable<T> {\n builder(): BuilderOf<T>\n}\n\n/** Decorator class kind for devtools introspection */\nexport type ClassKind =\n | 'service'\n | 'controller'\n | 'repository'\n | 'component'\n | 'injectable'\n | 'factory'\n | 'instance'\n | 'unknown'\n\n/** PostConstruct lifecycle status */\nexport type PostConstructStatus = 'pending' | 'completed' | 'failed' | 'skipped'\n\n/** Symbol-based metadata keys for the DI system */\nexport const METADATA = {\n INJECTABLE: Symbol('kick:injectable'),\n SCOPE: Symbol('kick:scope'),\n CLASS_KIND: Symbol('kick:class-kind'),\n AUTOWIRED: Symbol('kick:autowired'),\n INJECT: Symbol('kick:inject'),\n POST_CONSTRUCT: Symbol('kick:post_construct'),\n BUILDER: Symbol('kick:builder'),\n QUERY_PARAMS: Symbol('kick:query:params'),\n CONTROLLER_PATH: Symbol('kick:controller:path'),\n ROUTES: Symbol('kick:routes'),\n CLASS_MIDDLEWARES: Symbol('kick:class:middlewares'),\n METHOD_MIDDLEWARES: Symbol('kick:method:middlewares'),\n FILE_UPLOAD: Symbol('kick:file:upload'),\n VALUE: Symbol('kick:value'),\n // TypeScript emit metadata keys\n PARAM_TYPES: 'design:paramtypes',\n PROPERTY_TYPE: 'design:type',\n RETURN_TYPE: 'design:returntype',\n} as const\n"],"mappings":";;;;;;;;;;;;;AAGA,IAAY,QAAL,yBAAA,OAAA;AACL,OAAA,eAAA;AACA,OAAA,eAAA;;AAEA,OAAA,aAAA;;KACD;;AAsCD,MAAa,WAAW;CACtB,YAAY,OAAO,kBAAkB;CACrC,OAAO,OAAO,aAAa;CAC3B,YAAY,OAAO,kBAAkB;CACrC,WAAW,OAAO,iBAAiB;CACnC,QAAQ,OAAO,cAAc;CAC7B,gBAAgB,OAAO,sBAAsB;CAC7C,SAAS,OAAO,eAAe;CAC/B,cAAc,OAAO,oBAAoB;CACzC,iBAAiB,OAAO,uBAAuB;CAC/C,QAAQ,OAAO,cAAc;CAC7B,mBAAmB,OAAO,yBAAyB;CACnD,oBAAoB,OAAO,0BAA0B;CACrD,aAAa,OAAO,mBAAmB;CACvC,OAAO,OAAO,aAAa;CAE3B,aAAa;CACb,eAAe;CACf,aAAa;CACd"}
|
|
1
|
+
{"version":3,"file":"interfaces.mjs","names":[],"sources":["../../src/core/interfaces.ts"],"sourcesContent":["import 'reflect-metadata'\n\n/** Lifecycle scope for DI registrations */\nexport enum Scope {\n SINGLETON = 'singleton',\n TRANSIENT = 'transient',\n /** One instance per HTTP request, cached in AsyncLocalStorage. Throws outside request context. */\n REQUEST = 'request',\n}\n\n/** Generic constructor type */\nexport type Constructor<T = any> = new (...args: any[]) => T\n\n/** A value that may or may not be wrapped in a Promise */\nexport type MaybePromise<T = void> = T | Promise<T>\n\n/** Options for @Service, @Repository, @Component decorators */\nexport interface ServiceOptions {\n scope?: Scope\n}\n\n/** Fluent builder type */\nexport type BuilderOf<T> = {\n [K in keyof T as T[K] extends Function ? never : K]-?: (value: T[K]) => BuilderOf<T>\n} & { build(): T }\n\n/** Class with static builder() method */\nexport interface Buildable<T> {\n builder(): BuilderOf<T>\n}\n\n/** Decorator class kind for devtools introspection */\nexport type ClassKind =\n | 'service'\n | 'controller'\n | 'repository'\n | 'component'\n | 'injectable'\n | 'factory'\n | 'instance'\n | 'unknown'\n\n/** PostConstruct lifecycle status */\nexport type PostConstructStatus = 'pending' | 'completed' | 'failed' | 'skipped'\n\n/** Symbol-based metadata keys for the DI system */\nexport const METADATA = {\n INJECTABLE: Symbol('kick:injectable'),\n SCOPE: Symbol('kick:scope'),\n CLASS_KIND: Symbol('kick:class-kind'),\n AUTOWIRED: Symbol('kick:autowired'),\n INJECT: Symbol('kick:inject'),\n POST_CONSTRUCT: Symbol('kick:post_construct'),\n BUILDER: Symbol('kick:builder'),\n QUERY_PARAMS: Symbol('kick:query:params'),\n CONTROLLER_PATH: Symbol('kick:controller:path'),\n ROUTES: Symbol('kick:routes'),\n CLASS_MIDDLEWARES: Symbol('kick:class:middlewares'),\n METHOD_MIDDLEWARES: Symbol('kick:method:middlewares'),\n CLASS_CONTRIBUTORS: Symbol('kick:class:contributors'),\n METHOD_CONTRIBUTORS: Symbol('kick:method:contributors'),\n FILE_UPLOAD: Symbol('kick:file:upload'),\n VALUE: Symbol('kick:value'),\n // TypeScript emit metadata keys\n PARAM_TYPES: 'design:paramtypes',\n PROPERTY_TYPE: 'design:type',\n RETURN_TYPE: 'design:returntype',\n} as const\n"],"mappings":";;;;;;;;;;;;;AAGA,IAAY,QAAL,yBAAA,OAAA;AACL,OAAA,eAAA;AACA,OAAA,eAAA;;AAEA,OAAA,aAAA;;KACD;;AAsCD,MAAa,WAAW;CACtB,YAAY,OAAO,kBAAkB;CACrC,OAAO,OAAO,aAAa;CAC3B,YAAY,OAAO,kBAAkB;CACrC,WAAW,OAAO,iBAAiB;CACnC,QAAQ,OAAO,cAAc;CAC7B,gBAAgB,OAAO,sBAAsB;CAC7C,SAAS,OAAO,eAAe;CAC/B,cAAc,OAAO,oBAAoB;CACzC,iBAAiB,OAAO,uBAAuB;CAC/C,QAAQ,OAAO,cAAc;CAC7B,mBAAmB,OAAO,yBAAyB;CACnD,oBAAoB,OAAO,0BAA0B;CACrD,oBAAoB,OAAO,0BAA0B;CACrD,qBAAqB,OAAO,2BAA2B;CACvD,aAAa,OAAO,mBAAmB;CACvC,OAAO,OAAO,aAAa;CAE3B,aAAa;CACb,eAAe;CACf,aAAa;CACd"}
|
package/dist/core/logger.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { a as logger, i as createLogger, n as Logger, o as rootLogger, r as LoggerProvider, t as ConsoleLoggerProvider } from "../logger-
|
|
2
|
+
import { a as logger, i as createLogger, n as Logger, o as rootLogger, r as LoggerProvider, t as ConsoleLoggerProvider } from "../logger-GK8yT0BD.mjs";
|
|
3
3
|
export { ConsoleLoggerProvider, Logger, LoggerProvider, createLogger, logger, rootLogger };
|
package/dist/core/logger.mjs
CHANGED
package/dist/core/path.d.mts
CHANGED
package/dist/core/path.mjs
CHANGED
package/dist/core/plugin.d.mts
CHANGED
package/dist/core/plugin.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
|
|
2
|
-
import { a as isRef, c as toRefs, i as computed, l as unref, n as Ref, o as reactive, r as WatchOptions, s as ref, t as ComputedRef, u as watch } from "../reactivity-
|
|
2
|
+
import { a as isRef, c as toRefs, i as computed, l as unref, n as Ref, o as reactive, r as WatchOptions, s as ref, t as ComputedRef, u as watch } from "../reactivity-CczHu3R-.mjs";
|
|
3
3
|
export { ComputedRef, Ref, WatchOptions, computed, isRef, reactive, ref, toRefs, unref, watch };
|
package/dist/core/reactivity.mjs
CHANGED