@esmx/core 3.0.0-rc.29 → 3.0.0-rc.31
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/manifest-json.d.ts +24 -24
- package/package.json +4 -4
- package/src/manifest-json.ts +24 -24
package/dist/manifest-json.d.ts
CHANGED
|
@@ -2,53 +2,53 @@ import type { BuildSsrTarget } from './core';
|
|
|
2
2
|
import type { ParsedModuleConfig } from './module-config';
|
|
3
3
|
export interface ManifestJson {
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
5
|
+
* Module name
|
|
6
6
|
*/
|
|
7
7
|
name: string;
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
9
|
+
* Import mappings
|
|
10
10
|
*/
|
|
11
11
|
imports: Record<string, string>;
|
|
12
12
|
/**
|
|
13
|
-
*
|
|
14
|
-
*
|
|
13
|
+
* Export item configuration
|
|
14
|
+
* Type: Record<export path, export item information>
|
|
15
15
|
*/
|
|
16
16
|
exports: ManifestJsonExports;
|
|
17
17
|
/**
|
|
18
|
-
*
|
|
18
|
+
* Build output file list
|
|
19
19
|
*/
|
|
20
20
|
buildFiles: string[];
|
|
21
21
|
/**
|
|
22
|
-
*
|
|
23
|
-
*
|
|
22
|
+
* Compiled file information
|
|
23
|
+
* Type: Record<source file, compilation information>
|
|
24
24
|
*/
|
|
25
25
|
chunks: ManifestJsonChunks;
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
28
|
-
*
|
|
29
|
-
*
|
|
28
|
+
* Export item configuration mapping
|
|
29
|
+
* Type: Record<export path, export item information>
|
|
30
30
|
*/
|
|
31
31
|
export type ManifestJsonExports = Record<string, ManifestJsonExport>;
|
|
32
32
|
/**
|
|
33
|
-
*
|
|
33
|
+
* Export item information
|
|
34
34
|
*/
|
|
35
35
|
export interface ManifestJsonExport {
|
|
36
36
|
/**
|
|
37
|
-
*
|
|
37
|
+
* Export item name
|
|
38
38
|
*/
|
|
39
39
|
name: string;
|
|
40
40
|
/**
|
|
41
|
-
*
|
|
42
|
-
* - true:
|
|
43
|
-
* - false:
|
|
41
|
+
* Whether to rewrite module import paths
|
|
42
|
+
* - true: Rewrite to '{serviceName}/{exportName}' format
|
|
43
|
+
* - false: Maintain original import paths
|
|
44
44
|
*/
|
|
45
45
|
rewrite: boolean;
|
|
46
46
|
/**
|
|
47
|
-
*
|
|
47
|
+
* File path corresponding to the export item
|
|
48
48
|
*/
|
|
49
49
|
file: string;
|
|
50
50
|
/**
|
|
51
|
-
*
|
|
51
|
+
* Identifier for the export item
|
|
52
52
|
*/
|
|
53
53
|
identifier: string;
|
|
54
54
|
}
|
|
@@ -56,37 +56,37 @@ export type ManifestJsonChunks = Record<string, ManifestJsonChunk>;
|
|
|
56
56
|
export interface ManifestJsonChunk {
|
|
57
57
|
name: string;
|
|
58
58
|
/**
|
|
59
|
-
*
|
|
59
|
+
* Current compiled JS file.
|
|
60
60
|
*/
|
|
61
61
|
js: string;
|
|
62
62
|
/**
|
|
63
|
-
*
|
|
63
|
+
* Current compiled CSS files.
|
|
64
64
|
*/
|
|
65
65
|
css: string[];
|
|
66
66
|
/**
|
|
67
|
-
*
|
|
67
|
+
* Other resource files.
|
|
68
68
|
*/
|
|
69
69
|
resources: string[];
|
|
70
70
|
/**
|
|
71
|
-
*
|
|
71
|
+
* Build output sizes.
|
|
72
72
|
*/
|
|
73
73
|
sizes: ManifestJsonChunkSizes;
|
|
74
74
|
}
|
|
75
75
|
export interface ManifestJsonChunkSizes {
|
|
76
76
|
/**
|
|
77
|
-
* JavaScript
|
|
77
|
+
* JavaScript file size in bytes
|
|
78
78
|
*/
|
|
79
79
|
js: number;
|
|
80
80
|
/**
|
|
81
|
-
* CSS
|
|
81
|
+
* CSS file size in bytes
|
|
82
82
|
*/
|
|
83
83
|
css: number;
|
|
84
84
|
/**
|
|
85
|
-
*
|
|
85
|
+
* Resource file size in bytes
|
|
86
86
|
*/
|
|
87
87
|
resource: number;
|
|
88
88
|
}
|
|
89
89
|
/**
|
|
90
|
-
*
|
|
90
|
+
* Get service manifest files
|
|
91
91
|
*/
|
|
92
92
|
export declare function getManifestList(target: BuildSsrTarget, moduleConfig: ParsedModuleConfig): Promise<ManifestJson[]>;
|
package/package.json
CHANGED
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"build": "unbuild"
|
|
60
60
|
},
|
|
61
61
|
"dependencies": {
|
|
62
|
-
"@esmx/import": "3.0.0-rc.
|
|
62
|
+
"@esmx/import": "3.0.0-rc.31",
|
|
63
63
|
"@types/serialize-javascript": "^5.0.4",
|
|
64
64
|
"es-module-lexer": "^1.7.0",
|
|
65
65
|
"find": "^0.3.0",
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
},
|
|
69
69
|
"devDependencies": {
|
|
70
70
|
"@biomejs/biome": "1.9.4",
|
|
71
|
-
"@esmx/lint": "3.0.0-rc.
|
|
71
|
+
"@esmx/lint": "3.0.0-rc.31",
|
|
72
72
|
"@types/find": "^0.2.4",
|
|
73
73
|
"@types/node": "^24.0.0",
|
|
74
74
|
"@types/send": "^0.17.4",
|
|
@@ -79,7 +79,7 @@
|
|
|
79
79
|
"unbuild": "3.5.0",
|
|
80
80
|
"vitest": "3.2.4"
|
|
81
81
|
},
|
|
82
|
-
"version": "3.0.0-rc.
|
|
82
|
+
"version": "3.0.0-rc.31",
|
|
83
83
|
"type": "module",
|
|
84
84
|
"private": false,
|
|
85
85
|
"exports": {
|
|
@@ -102,5 +102,5 @@
|
|
|
102
102
|
"template",
|
|
103
103
|
"public"
|
|
104
104
|
],
|
|
105
|
-
"gitHead": "
|
|
105
|
+
"gitHead": "d472904500f5d697cd61b99b012570f6b063c580"
|
|
106
106
|
}
|
package/src/manifest-json.ts
CHANGED
|
@@ -6,55 +6,55 @@ import type { ParsedModuleConfig } from './module-config';
|
|
|
6
6
|
|
|
7
7
|
export interface ManifestJson {
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
9
|
+
* Module name
|
|
10
10
|
*/
|
|
11
11
|
name: string;
|
|
12
12
|
/**
|
|
13
|
-
*
|
|
13
|
+
* Import mappings
|
|
14
14
|
*/
|
|
15
15
|
imports: Record<string, string>;
|
|
16
16
|
/**
|
|
17
|
-
*
|
|
18
|
-
*
|
|
17
|
+
* Export item configuration
|
|
18
|
+
* Type: Record<export path, export item information>
|
|
19
19
|
*/
|
|
20
20
|
exports: ManifestJsonExports;
|
|
21
21
|
/**
|
|
22
|
-
*
|
|
22
|
+
* Build output file list
|
|
23
23
|
*/
|
|
24
24
|
buildFiles: string[];
|
|
25
25
|
/**
|
|
26
|
-
*
|
|
27
|
-
*
|
|
26
|
+
* Compiled file information
|
|
27
|
+
* Type: Record<source file, compilation information>
|
|
28
28
|
*/
|
|
29
29
|
chunks: ManifestJsonChunks;
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
/**
|
|
33
|
-
*
|
|
34
|
-
*
|
|
33
|
+
* Export item configuration mapping
|
|
34
|
+
* Type: Record<export path, export item information>
|
|
35
35
|
*/
|
|
36
36
|
export type ManifestJsonExports = Record<string, ManifestJsonExport>;
|
|
37
37
|
|
|
38
38
|
/**
|
|
39
|
-
*
|
|
39
|
+
* Export item information
|
|
40
40
|
*/
|
|
41
41
|
export interface ManifestJsonExport {
|
|
42
42
|
/**
|
|
43
|
-
*
|
|
43
|
+
* Export item name
|
|
44
44
|
*/
|
|
45
45
|
name: string;
|
|
46
46
|
/**
|
|
47
|
-
*
|
|
48
|
-
* - true:
|
|
49
|
-
* - false:
|
|
47
|
+
* Whether to rewrite module import paths
|
|
48
|
+
* - true: Rewrite to '{serviceName}/{exportName}' format
|
|
49
|
+
* - false: Maintain original import paths
|
|
50
50
|
*/
|
|
51
51
|
rewrite: boolean;
|
|
52
52
|
/**
|
|
53
|
-
*
|
|
53
|
+
* File path corresponding to the export item
|
|
54
54
|
*/
|
|
55
55
|
file: string;
|
|
56
56
|
/**
|
|
57
|
-
*
|
|
57
|
+
* Identifier for the export item
|
|
58
58
|
*/
|
|
59
59
|
identifier: string;
|
|
60
60
|
}
|
|
@@ -64,40 +64,40 @@ export type ManifestJsonChunks = Record<string, ManifestJsonChunk>;
|
|
|
64
64
|
export interface ManifestJsonChunk {
|
|
65
65
|
name: string;
|
|
66
66
|
/**
|
|
67
|
-
*
|
|
67
|
+
* Current compiled JS file.
|
|
68
68
|
*/
|
|
69
69
|
js: string;
|
|
70
70
|
/**
|
|
71
|
-
*
|
|
71
|
+
* Current compiled CSS files.
|
|
72
72
|
*/
|
|
73
73
|
css: string[];
|
|
74
74
|
/**
|
|
75
|
-
*
|
|
75
|
+
* Other resource files.
|
|
76
76
|
*/
|
|
77
77
|
resources: string[];
|
|
78
78
|
/**
|
|
79
|
-
*
|
|
79
|
+
* Build output sizes.
|
|
80
80
|
*/
|
|
81
81
|
sizes: ManifestJsonChunkSizes;
|
|
82
82
|
}
|
|
83
83
|
|
|
84
84
|
export interface ManifestJsonChunkSizes {
|
|
85
85
|
/**
|
|
86
|
-
* JavaScript
|
|
86
|
+
* JavaScript file size in bytes
|
|
87
87
|
*/
|
|
88
88
|
js: number;
|
|
89
89
|
/**
|
|
90
|
-
* CSS
|
|
90
|
+
* CSS file size in bytes
|
|
91
91
|
*/
|
|
92
92
|
css: number;
|
|
93
93
|
/**
|
|
94
|
-
*
|
|
94
|
+
* Resource file size in bytes
|
|
95
95
|
*/
|
|
96
96
|
resource: number;
|
|
97
97
|
}
|
|
98
98
|
|
|
99
99
|
/**
|
|
100
|
-
*
|
|
100
|
+
* Get service manifest files
|
|
101
101
|
*/
|
|
102
102
|
export async function getManifestList(
|
|
103
103
|
target: BuildSsrTarget,
|