@modern-js/module-tools 2.39.2 → 2.40.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/cli.js +0 -8
- package/lib/types.d.ts +0 -35
- package/package.json +14 -14
- package/dist/config/legacySchema.d.ts +0 -649
- package/dist/config/legacySchema.js +0 -288
- package/dist/config/schema.d.ts +0 -889
- package/dist/config/schema.js +0 -360
package/dist/cli.js
CHANGED
|
@@ -35,10 +35,7 @@ var import_utils = require("@modern-js/utils");
|
|
|
35
35
|
var import_hooks = require("./hooks");
|
|
36
36
|
var import_plugins = require("./plugins");
|
|
37
37
|
var import_command = require("./command");
|
|
38
|
-
var import_merge = require("./config/merge");
|
|
39
38
|
var import_onExit = require("./utils/onExit");
|
|
40
|
-
var import_legacySchema = require("./config/legacySchema");
|
|
41
|
-
var import_schema = require("./config/schema");
|
|
42
39
|
const moduleTools = () => ({
|
|
43
40
|
name: "@modern-js/module-tools",
|
|
44
41
|
registerHook: import_hooks.registerHook,
|
|
@@ -67,13 +64,8 @@ const setup = async (api) => {
|
|
|
67
64
|
await hookRunners.afterDev();
|
|
68
65
|
});
|
|
69
66
|
};
|
|
70
|
-
const validateSchema = async () => {
|
|
71
|
-
const userConfig = api.useConfigContext();
|
|
72
|
-
return (0, import_merge.isLegacyUserConfig)(userConfig) ? import_legacySchema.legacySchema : import_schema.schema;
|
|
73
|
-
};
|
|
74
67
|
return {
|
|
75
68
|
prepare,
|
|
76
|
-
validateSchema,
|
|
77
69
|
async commands({ program }) {
|
|
78
70
|
await (0, import_command.buildCommand)(program, api);
|
|
79
71
|
await (0, import_command.devCommand)(program, api);
|
package/lib/types.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
/// <reference types="react" />
|
|
3
|
-
/// <reference types="react-dom" />
|
|
4
3
|
|
|
5
4
|
declare namespace NodeJS {
|
|
6
5
|
interface ProcessEnv {
|
|
@@ -9,11 +8,6 @@ declare namespace NodeJS {
|
|
|
9
8
|
}
|
|
10
9
|
}
|
|
11
10
|
|
|
12
|
-
declare module '*.bmp' {
|
|
13
|
-
const src: string;
|
|
14
|
-
export default src;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
11
|
declare module '*.gif' {
|
|
18
12
|
const src: string;
|
|
19
13
|
export default src;
|
|
@@ -34,10 +28,6 @@ declare module '*.png' {
|
|
|
34
28
|
export default src;
|
|
35
29
|
}
|
|
36
30
|
|
|
37
|
-
declare module '*.ico' {
|
|
38
|
-
const src: string;
|
|
39
|
-
export default src;
|
|
40
|
-
}
|
|
41
31
|
|
|
42
32
|
declare module '*.webp' {
|
|
43
33
|
const src: string;
|
|
@@ -89,29 +79,4 @@ declare module '*.module.sass' {
|
|
|
89
79
|
export default classes;
|
|
90
80
|
}
|
|
91
81
|
|
|
92
|
-
declare module '*.md' {
|
|
93
|
-
const src: string;
|
|
94
|
-
export default src;
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
declare module '*.hbs' {
|
|
98
|
-
const src: string;
|
|
99
|
-
export default src;
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
declare module '*.yaml' {
|
|
103
|
-
const src: string;
|
|
104
|
-
export default src;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
declare module '*.toml' {
|
|
108
|
-
const src: string;
|
|
109
|
-
export default src;
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
declare module '*.xml' {
|
|
113
|
-
const src: string;
|
|
114
|
-
export default src;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
82
|
declare module '@modern-js/runtime/*' {}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@modern-js/module-tools",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.40.0",
|
|
4
4
|
"description": "Simple, powerful, high-performance modern npm package development solution.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"modern",
|
|
@@ -71,15 +71,15 @@
|
|
|
71
71
|
"tapable": "2.2.1",
|
|
72
72
|
"terser": "5.19.2",
|
|
73
73
|
"tsconfig-paths-webpack-plugin": "4.1.0",
|
|
74
|
-
"@modern-js/core": "2.
|
|
75
|
-
"@modern-js/
|
|
76
|
-
"@modern-js/
|
|
77
|
-
"@modern-js/plugin-
|
|
78
|
-
"@modern-js/plugin-
|
|
79
|
-
"@modern-js/
|
|
80
|
-
"@modern-js/
|
|
81
|
-
"@modern-js/
|
|
82
|
-
"@modern-js/utils": "2.
|
|
74
|
+
"@modern-js/core": "2.40.0",
|
|
75
|
+
"@modern-js/new-action": "2.40.0",
|
|
76
|
+
"@modern-js/plugin": "2.40.0",
|
|
77
|
+
"@modern-js/plugin-changeset": "2.40.0",
|
|
78
|
+
"@modern-js/plugin-i18n": "2.40.0",
|
|
79
|
+
"@modern-js/plugin-lint": "2.40.0",
|
|
80
|
+
"@modern-js/types": "2.40.0",
|
|
81
|
+
"@modern-js/upgrade": "2.40.0",
|
|
82
|
+
"@modern-js/utils": "2.40.0"
|
|
83
83
|
},
|
|
84
84
|
"devDependencies": {
|
|
85
85
|
"@types/babel__generator": "7.6.4",
|
|
@@ -87,10 +87,10 @@
|
|
|
87
87
|
"@types/convert-source-map": "1.5.2",
|
|
88
88
|
"@types/node": "^14",
|
|
89
89
|
"typescript": "^5",
|
|
90
|
-
"@modern-js/builder-webpack-provider": "2.
|
|
91
|
-
"@modern-js/self": "npm:@modern-js/module-tools@2.
|
|
92
|
-
"@scripts/
|
|
93
|
-
"@scripts/
|
|
90
|
+
"@modern-js/builder-webpack-provider": "2.40.0",
|
|
91
|
+
"@modern-js/self": "npm:@modern-js/module-tools@2.40.0",
|
|
92
|
+
"@scripts/build": "2.40.0",
|
|
93
|
+
"@scripts/vitest-config": "2.40.0"
|
|
94
94
|
},
|
|
95
95
|
"peerDependencies": {
|
|
96
96
|
"typescript": "^4 || ^5"
|