assemblerjs 1.1.17 → 1.1.19
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 +1 -0
- package/dist/index13.js +97 -82
- package/dist/index13.mjs +97 -82
- package/dist/index18.js +1 -1
- package/dist/index18.mjs +1 -1
- package/dist/index19.js +1 -1
- package/dist/index19.mjs +1 -1
- package/dist/index20.js +1 -1
- package/dist/index20.mjs +1 -1
- package/dist/index21.js +1 -1
- package/dist/index21.mjs +1 -1
- package/dist/index22.js +1 -1
- package/dist/index22.mjs +1 -1
- package/dist/index23.js +1 -1
- package/dist/index23.mjs +1 -1
- package/dist/index24.js +1 -1
- package/dist/index24.mjs +1 -1
- package/dist/index27.js +1 -1
- package/dist/index27.mjs +1 -1
- package/dist/index31.js +100 -35
- package/dist/index31.mjs +100 -34
- package/dist/index32.js +24 -101
- package/dist/index32.mjs +24 -101
- package/dist/index33.js +152 -22
- package/dist/index33.mjs +151 -22
- package/dist/index34.js +44 -16
- package/dist/index34.mjs +44 -16
- package/dist/index35.js +66 -145
- package/dist/index35.mjs +67 -145
- package/dist/index36.js +50 -45
- package/dist/index36.mjs +50 -45
- package/dist/index37.js +28 -76
- package/dist/index37.mjs +28 -76
- package/dist/index38.js +161 -50
- package/dist/index38.mjs +161 -50
- package/dist/index39.js +60 -28
- package/dist/index39.mjs +60 -28
- package/dist/index4.js +7 -7
- package/dist/index4.mjs +7 -7
- package/dist/index40.js +32 -158
- package/dist/index40.mjs +31 -158
- package/dist/index41.js +16 -57
- package/dist/index41.mjs +16 -57
- package/dist/index44.js +28 -941
- package/dist/index44.mjs +27 -941
- package/dist/index45.js +194 -2
- package/dist/index45.mjs +194 -2
- package/dist/index46.js +942 -2
- package/dist/index46.mjs +942 -2
- package/dist/index47.js +2 -29
- package/dist/index47.mjs +2 -28
- package/dist/index48.js +2 -194
- package/dist/index48.mjs +2 -194
- package/dist/index49.js +1 -1
- package/dist/index49.mjs +1 -1
- package/dist/index50.js +2 -2
- package/dist/index50.mjs +2 -2
- package/package.json +1 -1
package/dist/index41.js
CHANGED
|
@@ -2,68 +2,27 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
detect() {
|
|
9
|
-
return [];
|
|
5
|
+
class ResolverStore {
|
|
6
|
+
static register(e, r) {
|
|
7
|
+
this.resolvers.set(e, r);
|
|
10
8
|
}
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
const s = new Set();
|
|
16
|
-
for (const [n] of e){
|
|
17
|
-
if (s.has(n)) continue;
|
|
18
|
-
const r = [];
|
|
19
|
-
const o = new Set();
|
|
20
|
-
if (this.hasCycleDFS(n, r, o, s, e)) {
|
|
21
|
-
const e = r.findIndex((e)=>e === n);
|
|
22
|
-
if (e >= 0) {
|
|
23
|
-
const s = r.slice(e).map((e)=>t(e));
|
|
24
|
-
c.push({
|
|
25
|
-
cycle: s,
|
|
26
|
-
path: s.join(' → ')
|
|
27
|
-
});
|
|
28
|
-
}
|
|
29
|
-
}
|
|
9
|
+
static getResolver(e) {
|
|
10
|
+
const r = this.resolvers.get(e);
|
|
11
|
+
if (!r) {
|
|
12
|
+
throw new Error(`No resolver found for decorator type: ${e}`);
|
|
30
13
|
}
|
|
31
|
-
return
|
|
14
|
+
return new r();
|
|
32
15
|
}
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
t.push(e);
|
|
36
|
-
return true;
|
|
37
|
-
}
|
|
38
|
-
if (s.has(e)) {
|
|
39
|
-
return false;
|
|
40
|
-
}
|
|
41
|
-
t.push(e);
|
|
42
|
-
c.add(e);
|
|
43
|
-
const r = n.get(e);
|
|
44
|
-
if (r?.dependencies && r.dependencies.length > 0) {
|
|
45
|
-
for (const e of r.dependencies){
|
|
46
|
-
if (this.hasCycleDFS(e, t, c, s, n)) {
|
|
47
|
-
return true;
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
c.delete(e);
|
|
52
|
-
s.add(e);
|
|
53
|
-
return false;
|
|
54
|
-
}
|
|
55
|
-
};
|
|
56
|
-
class CycleDetector {
|
|
57
|
-
static getInstance() {
|
|
58
|
-
return CycleDetector.instance;
|
|
16
|
+
static hasResolver(e) {
|
|
17
|
+
return this.resolvers.has(e);
|
|
59
18
|
}
|
|
60
|
-
static
|
|
61
|
-
|
|
19
|
+
static getRegisteredTypes() {
|
|
20
|
+
return Array.from(this.resolvers.keys());
|
|
62
21
|
}
|
|
63
|
-
static
|
|
64
|
-
|
|
22
|
+
static clear() {
|
|
23
|
+
this.resolvers.clear();
|
|
65
24
|
}
|
|
66
25
|
}
|
|
67
|
-
|
|
26
|
+
ResolverStore.resolvers = new Map();
|
|
68
27
|
|
|
69
|
-
exports.
|
|
28
|
+
exports.ResolverStore = ResolverStore;
|
package/dist/index41.mjs
CHANGED
|
@@ -1,65 +1,24 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
detect() {
|
|
5
|
-
return [];
|
|
1
|
+
class ResolverStore {
|
|
2
|
+
static register(e, r) {
|
|
3
|
+
this.resolvers.set(e, r);
|
|
6
4
|
}
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
const s = new Set();
|
|
12
|
-
for (const [n] of e){
|
|
13
|
-
if (s.has(n)) continue;
|
|
14
|
-
const r = [];
|
|
15
|
-
const o = new Set();
|
|
16
|
-
if (this.hasCycleDFS(n, r, o, s, e)) {
|
|
17
|
-
const e = r.findIndex((e)=>e === n);
|
|
18
|
-
if (e >= 0) {
|
|
19
|
-
const s = r.slice(e).map((e)=>t(e));
|
|
20
|
-
c.push({
|
|
21
|
-
cycle: s,
|
|
22
|
-
path: s.join(' → ')
|
|
23
|
-
});
|
|
24
|
-
}
|
|
25
|
-
}
|
|
5
|
+
static getResolver(e) {
|
|
6
|
+
const r = this.resolvers.get(e);
|
|
7
|
+
if (!r) {
|
|
8
|
+
throw new Error(`No resolver found for decorator type: ${e}`);
|
|
26
9
|
}
|
|
27
|
-
return
|
|
10
|
+
return new r();
|
|
28
11
|
}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
t.push(e);
|
|
32
|
-
return true;
|
|
33
|
-
}
|
|
34
|
-
if (s.has(e)) {
|
|
35
|
-
return false;
|
|
36
|
-
}
|
|
37
|
-
t.push(e);
|
|
38
|
-
c.add(e);
|
|
39
|
-
const r = n.get(e);
|
|
40
|
-
if (r?.dependencies && r.dependencies.length > 0) {
|
|
41
|
-
for (const e of r.dependencies){
|
|
42
|
-
if (this.hasCycleDFS(e, t, c, s, n)) {
|
|
43
|
-
return true;
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
c.delete(e);
|
|
48
|
-
s.add(e);
|
|
49
|
-
return false;
|
|
50
|
-
}
|
|
51
|
-
};
|
|
52
|
-
class CycleDetector {
|
|
53
|
-
static getInstance() {
|
|
54
|
-
return CycleDetector.instance;
|
|
12
|
+
static hasResolver(e) {
|
|
13
|
+
return this.resolvers.has(e);
|
|
55
14
|
}
|
|
56
|
-
static
|
|
57
|
-
|
|
15
|
+
static getRegisteredTypes() {
|
|
16
|
+
return Array.from(this.resolvers.keys());
|
|
58
17
|
}
|
|
59
|
-
static
|
|
60
|
-
|
|
18
|
+
static clear() {
|
|
19
|
+
this.resolvers.clear();
|
|
61
20
|
}
|
|
62
21
|
}
|
|
63
|
-
|
|
22
|
+
ResolverStore.resolvers = new Map();
|
|
64
23
|
|
|
65
|
-
export {
|
|
24
|
+
export { ResolverStore };
|