@nmtjs/core 0.12.4 → 0.12.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/dist/constants.d.ts +20 -0
- package/dist/constants.js +10 -12
- package/dist/container.d.ts +46 -0
- package/dist/container.js +310 -277
- package/dist/enums.d.ts +18 -0
- package/dist/enums.js +20 -22
- package/dist/hooks.d.ts +19 -0
- package/dist/hooks.js +39 -35
- package/dist/index.d.ts +11 -0
- package/dist/index.js +3 -2
- package/dist/injectables.d.ts +115 -0
- package/dist/injectables.js +194 -179
- package/dist/logger.d.ts +9 -0
- package/dist/logger.js +54 -58
- package/dist/metadata.d.ts +13 -0
- package/dist/metadata.js +10 -15
- package/dist/plugin.d.ts +12 -0
- package/dist/plugin.js +1 -7
- package/dist/registry.d.ts +19 -0
- package/dist/registry.js +17 -18
- package/dist/types.d.ts +11 -0
- package/dist/types.js +0 -2
- package/dist/utils/functions.d.ts +6 -0
- package/dist/utils/functions.js +30 -32
- package/dist/utils/index.d.ts +3 -0
- package/dist/utils/index.js +0 -2
- package/dist/utils/pool.d.ts +18 -0
- package/dist/utils/pool.js +103 -90
- package/dist/utils/semaphore.d.ts +13 -0
- package/dist/utils/semaphore.js +53 -46
- package/package.json +9 -8
- package/src/hooks.ts +1 -3
- package/src/index.ts +4 -0
- package/src/injectables.ts +2 -2
- package/src/logger.ts +1 -0
- package/src/plugin.ts +1 -1
- package/src/utils/pool.ts +1 -1
- package/src/utils/semaphore.ts +1 -1
- package/dist/constants.js.map +0 -1
- package/dist/container.js.map +0 -1
- package/dist/enums.js.map +0 -1
- package/dist/hooks.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/injectables.js.map +0 -1
- package/dist/logger.js.map +0 -1
- package/dist/metadata.js.map +0 -1
- package/dist/plugin.js.map +0 -1
- package/dist/registry.js.map +0 -1
- package/dist/types.js.map +0 -1
- package/dist/utils/functions.js.map +0 -1
- package/dist/utils/index.js.map +0 -1
- package/dist/utils/pool.js.map +0 -1
- package/dist/utils/semaphore.js.map +0 -1
package/dist/registry.js
CHANGED
|
@@ -1,25 +1,24 @@
|
|
|
1
1
|
import { Scope } from "./enums.js";
|
|
2
2
|
import { Hooks } from "./hooks.js";
|
|
3
|
-
import { getInjectableScope } from "./injectables.js";
|
|
3
|
+
import { getInjectableScope, } from "./injectables.js";
|
|
4
4
|
export class Registry {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
5
|
+
application;
|
|
6
|
+
hooks = new Hooks();
|
|
7
|
+
constructor(application) {
|
|
8
|
+
this.application = application;
|
|
9
|
+
}
|
|
10
|
+
registerHooks(hooks) {
|
|
11
|
+
Hooks.merge(hooks, this.hooks);
|
|
12
|
+
}
|
|
13
|
+
registerHook(name, callback) {
|
|
14
|
+
this.hooks.add(name, callback);
|
|
15
|
+
}
|
|
16
|
+
*getDependants() { }
|
|
17
|
+
clear() {
|
|
18
|
+
this.hooks.clear();
|
|
19
|
+
}
|
|
19
20
|
}
|
|
20
21
|
export const scopeErrorMessage = (name, scope = Scope.Global) => `${name} must be a ${scope} scope (including all nested dependencies)`;
|
|
21
22
|
export function hasInvalidScopeDeps(injectables, scope = Scope.Global) {
|
|
22
|
-
|
|
23
|
+
return injectables.some((injectable) => getInjectableScope(injectable) !== scope);
|
|
23
24
|
}
|
|
24
|
-
|
|
25
|
-
//# sourceMappingURL=registry.js.map
|
package/dist/types.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Container } from './container.ts';
|
|
2
|
+
import type { Hooks } from './hooks.ts';
|
|
3
|
+
import type { Logger } from './logger.ts';
|
|
4
|
+
import type { Registry } from './registry.ts';
|
|
5
|
+
export interface PluginContext {
|
|
6
|
+
logger: Logger;
|
|
7
|
+
registry: Registry;
|
|
8
|
+
hooks: Hooks;
|
|
9
|
+
container: Container;
|
|
10
|
+
}
|
|
11
|
+
export type Pattern = RegExp | string | ((value: string) => boolean);
|
package/dist/types.js
CHANGED
package/dist/utils/functions.js
CHANGED
|
@@ -1,37 +1,35 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Very simple pattern matching function.
|
|
3
|
-
*/
|
|
2
|
+
* Very simple pattern matching function.
|
|
3
|
+
*/
|
|
4
4
|
export function match(value, pattern) {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
5
|
+
if (typeof pattern === 'function') {
|
|
6
|
+
return pattern(value);
|
|
7
|
+
}
|
|
8
|
+
else if (typeof pattern === 'string') {
|
|
9
|
+
if (pattern === '*' || pattern === '**') {
|
|
10
|
+
return true;
|
|
11
|
+
}
|
|
12
|
+
else if (pattern.at(0) === '*' && pattern.at(-1) === '*') {
|
|
13
|
+
return value.includes(pattern.slice(1, -1));
|
|
14
|
+
}
|
|
15
|
+
else if (pattern.at(-1) === '*') {
|
|
16
|
+
return value.startsWith(pattern.slice(0, -1));
|
|
17
|
+
}
|
|
18
|
+
else if (pattern.at(0) === '*') {
|
|
19
|
+
return value.endsWith(pattern.slice(1));
|
|
20
|
+
}
|
|
21
|
+
else {
|
|
22
|
+
return value === pattern;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
else {
|
|
26
|
+
return pattern.test(value);
|
|
27
|
+
}
|
|
22
28
|
}
|
|
23
29
|
export function isJsFile(name) {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
"mjs",
|
|
30
|
-
"cjs",
|
|
31
|
-
"ts",
|
|
32
|
-
"mts",
|
|
33
|
-
"cts"
|
|
34
|
-
].includes(ext);
|
|
30
|
+
if (name.endsWith('.d.ts'))
|
|
31
|
+
return false;
|
|
32
|
+
const leading = name.split('.').slice(1);
|
|
33
|
+
const ext = leading.join('.');
|
|
34
|
+
return ['js', 'mjs', 'cjs', 'ts', 'mts', 'cts'].includes(ext);
|
|
35
35
|
}
|
|
36
|
-
|
|
37
|
-
//# sourceMappingURL=functions.js.map
|
package/dist/utils/index.js
CHANGED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
interface PoolOptions {
|
|
2
|
+
timeout?: number;
|
|
3
|
+
}
|
|
4
|
+
export declare class PoolError extends Error {
|
|
5
|
+
}
|
|
6
|
+
export declare class Pool<T = unknown> {
|
|
7
|
+
#private;
|
|
8
|
+
private readonly options;
|
|
9
|
+
constructor(options?: PoolOptions);
|
|
10
|
+
add(item: T): void;
|
|
11
|
+
remove(item: T): void;
|
|
12
|
+
capture(timeout?: number | undefined): Promise<T>;
|
|
13
|
+
next(exclusive?: boolean, timeout?: number | undefined): Promise<T>;
|
|
14
|
+
release(item: T): void;
|
|
15
|
+
isFree(item: T): boolean;
|
|
16
|
+
get items(): T[];
|
|
17
|
+
}
|
|
18
|
+
export {};
|
package/dist/utils/pool.js
CHANGED
|
@@ -1,92 +1,105 @@
|
|
|
1
|
-
export class PoolError extends Error {
|
|
1
|
+
export class PoolError extends Error {
|
|
2
|
+
}
|
|
3
|
+
// Fixed pool from https://github.com/metarhia/metautil
|
|
2
4
|
export class Pool {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
5
|
+
options;
|
|
6
|
+
#items = [];
|
|
7
|
+
#free = [];
|
|
8
|
+
#queue = [];
|
|
9
|
+
#current = 0;
|
|
10
|
+
#size = 0;
|
|
11
|
+
#available = 0;
|
|
12
|
+
constructor(options = {}) {
|
|
13
|
+
this.options = options;
|
|
14
|
+
}
|
|
15
|
+
add(item) {
|
|
16
|
+
if (this.#items.includes(item))
|
|
17
|
+
throw new PoolError('Item already exists');
|
|
18
|
+
this.#size++;
|
|
19
|
+
this.#available++;
|
|
20
|
+
this.#items.push(item);
|
|
21
|
+
this.#free.push(true);
|
|
22
|
+
}
|
|
23
|
+
remove(item) {
|
|
24
|
+
if (this.#size === 0)
|
|
25
|
+
throw new PoolError('Pool is empty');
|
|
26
|
+
const index = this.#items.indexOf(item);
|
|
27
|
+
if (index < 0)
|
|
28
|
+
throw new PoolError('Item is not in the pool');
|
|
29
|
+
const isCaptured = this.isFree(item);
|
|
30
|
+
if (isCaptured)
|
|
31
|
+
this.#available--;
|
|
32
|
+
this.#size--;
|
|
33
|
+
this.#current--;
|
|
34
|
+
this.#items.splice(index, 1);
|
|
35
|
+
this.#free.splice(index, 1);
|
|
36
|
+
}
|
|
37
|
+
capture(timeout = this.options.timeout) {
|
|
38
|
+
return this.next(true, timeout);
|
|
39
|
+
}
|
|
40
|
+
async next(exclusive = false, timeout = this.options.timeout) {
|
|
41
|
+
if (this.#size === 0)
|
|
42
|
+
throw new PoolError('Pool is empty');
|
|
43
|
+
if (this.#available === 0) {
|
|
44
|
+
return new Promise((resolve, reject) => {
|
|
45
|
+
const waiting = {
|
|
46
|
+
resolve: (item) => {
|
|
47
|
+
if (exclusive)
|
|
48
|
+
this.#capture(item);
|
|
49
|
+
resolve(item);
|
|
50
|
+
},
|
|
51
|
+
timer: undefined,
|
|
52
|
+
};
|
|
53
|
+
if (timeout) {
|
|
54
|
+
waiting.timer = setTimeout(() => {
|
|
55
|
+
waiting.resolve = undefined;
|
|
56
|
+
this.#queue.shift();
|
|
57
|
+
reject(new PoolError('Next item timeout'));
|
|
58
|
+
}, timeout);
|
|
59
|
+
}
|
|
60
|
+
this.#queue.push(waiting);
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
let item;
|
|
64
|
+
let free = false;
|
|
65
|
+
do {
|
|
66
|
+
item = this.#items[this.#current];
|
|
67
|
+
free = this.#free[this.#current];
|
|
68
|
+
this.#current++;
|
|
69
|
+
if (this.#current >= this.#size)
|
|
70
|
+
this.#current = 0;
|
|
71
|
+
} while (typeof item === 'undefined' || !free);
|
|
72
|
+
if (exclusive)
|
|
73
|
+
this.#capture(item);
|
|
74
|
+
return item;
|
|
75
|
+
}
|
|
76
|
+
release(item) {
|
|
77
|
+
const index = this.#items.indexOf(item);
|
|
78
|
+
if (index < 0)
|
|
79
|
+
throw new PoolError('Unexpected item');
|
|
80
|
+
if (this.#free[index])
|
|
81
|
+
throw new PoolError('Unable to release not captured item');
|
|
82
|
+
this.#free[index] = true;
|
|
83
|
+
this.#available++;
|
|
84
|
+
if (this.#queue.length > 0) {
|
|
85
|
+
const { resolve, timer } = this.#queue.shift();
|
|
86
|
+
clearTimeout(timer);
|
|
87
|
+
if (resolve)
|
|
88
|
+
setTimeout(resolve, 0, item);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
isFree(item) {
|
|
92
|
+
const index = this.#items.indexOf(item);
|
|
93
|
+
if (index < 0)
|
|
94
|
+
return false;
|
|
95
|
+
return this.#free[index];
|
|
96
|
+
}
|
|
97
|
+
get items() {
|
|
98
|
+
return [...this.#items];
|
|
99
|
+
}
|
|
100
|
+
#capture(item) {
|
|
101
|
+
const index = this.#items.indexOf(item);
|
|
102
|
+
this.#free[index] = false;
|
|
103
|
+
this.#available--;
|
|
104
|
+
}
|
|
90
105
|
}
|
|
91
|
-
|
|
92
|
-
//# sourceMappingURL=pool.js.map
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare class SemaphoreError extends Error {
|
|
2
|
+
}
|
|
3
|
+
export declare class Semaphore {
|
|
4
|
+
private readonly size;
|
|
5
|
+
private readonly timeout;
|
|
6
|
+
private counter;
|
|
7
|
+
private readonly queue;
|
|
8
|
+
constructor(concurrency: number, size?: number, timeout?: number);
|
|
9
|
+
enter(): Promise<void>;
|
|
10
|
+
leave(): void;
|
|
11
|
+
get isEmpty(): boolean;
|
|
12
|
+
get queueLength(): number;
|
|
13
|
+
}
|
package/dist/utils/semaphore.js
CHANGED
|
@@ -1,48 +1,55 @@
|
|
|
1
|
-
export class SemaphoreError extends Error {
|
|
1
|
+
export class SemaphoreError extends Error {
|
|
2
|
+
}
|
|
3
|
+
// Semaphore from https://github.com/metarhia/metautil
|
|
2
4
|
export class Semaphore {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
5
|
+
size;
|
|
6
|
+
timeout;
|
|
7
|
+
counter;
|
|
8
|
+
queue = [];
|
|
9
|
+
constructor(concurrency, size = 0, timeout = 0) {
|
|
10
|
+
this.size = size;
|
|
11
|
+
this.timeout = timeout;
|
|
12
|
+
this.counter = concurrency;
|
|
13
|
+
}
|
|
14
|
+
enter() {
|
|
15
|
+
if (this.counter > 0) {
|
|
16
|
+
this.counter--;
|
|
17
|
+
return Promise.resolve();
|
|
18
|
+
}
|
|
19
|
+
else if (this.queue.length >= this.size) {
|
|
20
|
+
return Promise.reject(new SemaphoreError('Queue is full'));
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
return new Promise((resolve, reject) => {
|
|
24
|
+
const waiting = { resolve };
|
|
25
|
+
waiting.timer = setTimeout(() => {
|
|
26
|
+
waiting.resolve = undefined;
|
|
27
|
+
this.queue.shift();
|
|
28
|
+
reject(new SemaphoreError('Timeout'));
|
|
29
|
+
}, this.timeout);
|
|
30
|
+
this.queue.push(waiting);
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
leave() {
|
|
35
|
+
if (this.queue.length === 0) {
|
|
36
|
+
this.counter++;
|
|
37
|
+
}
|
|
38
|
+
else {
|
|
39
|
+
const item = this.queue.shift();
|
|
40
|
+
if (item) {
|
|
41
|
+
const { resolve, timer } = item;
|
|
42
|
+
if (timer)
|
|
43
|
+
clearTimeout(timer);
|
|
44
|
+
if (resolve)
|
|
45
|
+
setTimeout(resolve, 0);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
get isEmpty() {
|
|
50
|
+
return this.queue.length === 0;
|
|
51
|
+
}
|
|
52
|
+
get queueLength() {
|
|
53
|
+
return this.queue.length;
|
|
54
|
+
}
|
|
46
55
|
}
|
|
47
|
-
|
|
48
|
-
//# sourceMappingURL=semaphore.js.map
|
package/package.json
CHANGED
|
@@ -3,22 +3,23 @@
|
|
|
3
3
|
"type": "module",
|
|
4
4
|
"exports": {
|
|
5
5
|
".": {
|
|
6
|
-
"types": "./
|
|
7
|
-
"import": "./dist/index.js"
|
|
6
|
+
"types": "./dist/index.d.ts",
|
|
7
|
+
"import": "./dist/index.js",
|
|
8
|
+
"module-sync": "./dist/index.js"
|
|
8
9
|
}
|
|
9
10
|
},
|
|
10
11
|
"peerDependencies": {
|
|
11
12
|
"pino": "^9.6.0",
|
|
12
13
|
"pino-pretty": "^13.0.0",
|
|
13
|
-
"@nmtjs/common": "0.12.
|
|
14
|
-
"@nmtjs/type": "0.12.
|
|
14
|
+
"@nmtjs/common": "0.12.6",
|
|
15
|
+
"@nmtjs/type": "0.12.6"
|
|
15
16
|
},
|
|
16
17
|
"devDependencies": {
|
|
17
18
|
"@types/node": "^20",
|
|
18
19
|
"pino": "^9.6.0",
|
|
19
20
|
"pino-pretty": "^13.0.0",
|
|
20
|
-
"@nmtjs/
|
|
21
|
-
"@nmtjs/
|
|
21
|
+
"@nmtjs/common": "0.12.6",
|
|
22
|
+
"@nmtjs/type": "0.12.6"
|
|
22
23
|
},
|
|
23
24
|
"files": [
|
|
24
25
|
"src",
|
|
@@ -26,9 +27,9 @@
|
|
|
26
27
|
"LICENSE.md",
|
|
27
28
|
"README.md"
|
|
28
29
|
],
|
|
29
|
-
"version": "0.12.
|
|
30
|
+
"version": "0.12.6",
|
|
30
31
|
"scripts": {
|
|
31
|
-
"build": "
|
|
32
|
+
"build": "tsc",
|
|
32
33
|
"type-check": "tsc --noEmit"
|
|
33
34
|
}
|
|
34
35
|
}
|
package/src/hooks.ts
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
import type { Callback } from '
|
|
1
|
+
import type { Callback } from '@nmtjs/common'
|
|
2
2
|
import { kHookCollection } from './constants.ts'
|
|
3
3
|
import type { Hook } from './enums.ts'
|
|
4
4
|
|
|
5
|
-
// import type { HookType } from './types.ts'
|
|
6
|
-
|
|
7
5
|
export interface HookType {
|
|
8
6
|
[key: string]: (...args: any[]) => any
|
|
9
7
|
// [Hook.AfterInitialize]: () => any
|
package/src/index.ts
CHANGED
package/src/injectables.ts
CHANGED
|
@@ -304,8 +304,8 @@ export const createClassInjectable = <
|
|
|
304
304
|
|
|
305
305
|
constructor(public $context: DependencyContext<D>) {}
|
|
306
306
|
|
|
307
|
-
|
|
308
|
-
|
|
307
|
+
async $onCreate() {}
|
|
308
|
+
async $onDispose() {}
|
|
309
309
|
}
|
|
310
310
|
|
|
311
311
|
InjectableClass.scope = resolveInjectableScope(
|
package/src/logger.ts
CHANGED
package/src/plugin.ts
CHANGED
package/src/utils/pool.ts
CHANGED
package/src/utils/semaphore.ts
CHANGED
package/dist/constants.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"mappings":"AAAA,OAAO,MAAMA,sBAAqC,OAAO,IACvD,gCACD;AAGD,OAAO,MAAMC,cAA6B,OAAO,IAAI,wBAAwB;AAG7E,OAAO,MAAMC,kBAAiC,OAAO,IACnD,4BACD;AAGD,OAAO,MAAMC,mBAAkC,OAAO,IACpD,6BACD;AAGD,OAAO,MAAMC,qBAAoC,OAAO,IACtD,+BACD;AAGD,OAAO,MAAMC,mBAAkC,OAAO,IACpD,6BACD;AAGD,OAAO,MAAMC,YAA2B,OAAO,IAAI,sBAAsB;AAGzE,OAAO,MAAMC,kBAAiC,OAAO,IACnD,4BACD;AAGD,OAAO,MAAMC,UAAyB,OAAO,IAAI,oBAAoB;AAGrE,OAAO,MAAMC,YAA2B,OAAO,IAAI,sBAAsB","names":["kOptionalDependency: unique symbol","kInjectable: unique symbol","kLazyInjectable: unique symbol","kValueInjectable: unique symbol","kFactoryInjectable: unique symbol","kClassInjectable: unique symbol","kProvider: unique symbol","kHookCollection: unique symbol","kPlugin: unique symbol","kMetadata: unique symbol"],"sources":["../src/constants.ts"],"sourcesContent":["export const kOptionalDependency: unique symbol = Symbol.for(\n 'neemata:OptionalDependencyKey',\n)\nexport type kOptionalDependency = typeof kOptionalDependency\n\nexport const kInjectable: unique symbol = Symbol.for('neemata:InjectableKey')\nexport type kInjectable = typeof kInjectable\n\nexport const kLazyInjectable: unique symbol = Symbol.for(\n 'neemata:LazyInjectableKey',\n)\nexport type kLazyInjectable = typeof kLazyInjectable\n\nexport const kValueInjectable: unique symbol = Symbol.for(\n 'neemata:ValueInjectableKey',\n)\nexport type kValueInjectable = typeof kValueInjectable\n\nexport const kFactoryInjectable: unique symbol = Symbol.for(\n 'neemata:FactoryInjectableKey',\n)\nexport type kFactoryInjectable = typeof kFactoryInjectable\n\nexport const kClassInjectable: unique symbol = Symbol.for(\n 'neemata:ClassInjectableKey',\n)\nexport type kClassInjectable = typeof kClassInjectable\n\nexport const kProvider: unique symbol = Symbol.for('neemata:ProviderKey')\nexport type kProvider = typeof kProvider\n\nexport const kHookCollection: unique symbol = Symbol.for(\n 'neemata:HookCollectionKey',\n)\nexport type kHookCollection = typeof kHookCollection\n\nexport const kPlugin: unique symbol = Symbol.for('neemata:PluginKey')\nexport type kPlugin = typeof kPlugin\n\nexport const kMetadata: unique symbol = Symbol.for('neemata:MetadataKey')\nexport type kMetadata = typeof kMetadata\n"],"version":3,"file":"constants.js"}
|