@modern-js/module-tools 1.21.0 → 1.21.2
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/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,45 @@
|
|
|
1
1
|
# @modern-js/module-tools
|
|
2
2
|
|
|
3
|
+
## 1.21.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [c85bcfc]
|
|
8
|
+
- Updated dependencies [9d4c0ba]
|
|
9
|
+
- @modern-js/style-compiler@1.21.2
|
|
10
|
+
- @modern-js/plugin@1.21.2
|
|
11
|
+
- @modern-js/new-action@1.21.2
|
|
12
|
+
- @modern-js/core@1.21.2
|
|
13
|
+
- @modern-js/css-config@1.21.2
|
|
14
|
+
- @modern-js/plugin-changeset@1.21.2
|
|
15
|
+
- @modern-js/plugin-jarvis@1.21.2
|
|
16
|
+
- @modern-js/babel-preset-module@1.21.2
|
|
17
|
+
- @modern-js/plugin-i18n@1.21.2
|
|
18
|
+
- @modern-js/babel-compiler@1.21.2
|
|
19
|
+
- @modern-js/upgrade@1.21.2
|
|
20
|
+
- @modern-js/utils@1.21.2
|
|
21
|
+
|
|
22
|
+
## 1.21.1
|
|
23
|
+
|
|
24
|
+
### Patch Changes
|
|
25
|
+
|
|
26
|
+
- fdea3b7: fix: support node-linker=hoist
|
|
27
|
+
|
|
28
|
+
fix: 支持 node-linker=hoist
|
|
29
|
+
|
|
30
|
+
- @modern-js/babel-preset-module@1.21.1
|
|
31
|
+
- @modern-js/core@1.21.1
|
|
32
|
+
- @modern-js/css-config@1.21.1
|
|
33
|
+
- @modern-js/plugin-changeset@1.21.1
|
|
34
|
+
- @modern-js/plugin-i18n@1.21.1
|
|
35
|
+
- @modern-js/plugin-jarvis@1.21.1
|
|
36
|
+
- @modern-js/new-action@1.21.1
|
|
37
|
+
- @modern-js/babel-compiler@1.21.1
|
|
38
|
+
- @modern-js/style-compiler@1.21.1
|
|
39
|
+
- @modern-js/plugin@1.21.1
|
|
40
|
+
- @modern-js/upgrade@1.21.1
|
|
41
|
+
- @modern-js/utils@1.21.1
|
|
42
|
+
|
|
3
43
|
## 1.21.0
|
|
4
44
|
|
|
5
45
|
### Patch Changes
|
|
@@ -85,11 +85,20 @@ export const resolveAlias = (modernConfig, config, watchFilenames = []) => {
|
|
|
85
85
|
}
|
|
86
86
|
};
|
|
87
87
|
export const getTscBinPath = appDirectory => {
|
|
88
|
-
const
|
|
88
|
+
const {
|
|
89
|
+
root
|
|
90
|
+
} = path.parse(appDirectory);
|
|
91
|
+
let currentDirectory = appDirectory;
|
|
92
|
+
|
|
93
|
+
while (currentDirectory !== root) {
|
|
94
|
+
const tscBinFile = path.join(currentDirectory, './node_modules/.bin/tsc');
|
|
95
|
+
|
|
96
|
+
if (fs.existsSync(tscBinFile)) {
|
|
97
|
+
return tscBinFile;
|
|
98
|
+
}
|
|
89
99
|
|
|
90
|
-
|
|
91
|
-
throw new Error('Failed to excute the `tsc` command, please check if `typescript` is installed correctly in the current directory.');
|
|
100
|
+
currentDirectory = path.dirname(currentDirectory);
|
|
92
101
|
}
|
|
93
102
|
|
|
94
|
-
|
|
103
|
+
throw new Error('Failed to excute the `tsc` command, please check if `typescript` is installed correctly in the current directory.');
|
|
95
104
|
};
|
|
@@ -110,13 +110,22 @@ const resolveAlias = (modernConfig, config, watchFilenames = []) => {
|
|
|
110
110
|
exports.resolveAlias = resolveAlias;
|
|
111
111
|
|
|
112
112
|
const getTscBinPath = appDirectory => {
|
|
113
|
-
const
|
|
113
|
+
const {
|
|
114
|
+
root
|
|
115
|
+
} = path.parse(appDirectory);
|
|
116
|
+
let currentDirectory = appDirectory;
|
|
117
|
+
|
|
118
|
+
while (currentDirectory !== root) {
|
|
119
|
+
const tscBinFile = path.join(currentDirectory, './node_modules/.bin/tsc');
|
|
120
|
+
|
|
121
|
+
if (_utils.fs.existsSync(tscBinFile)) {
|
|
122
|
+
return tscBinFile;
|
|
123
|
+
}
|
|
114
124
|
|
|
115
|
-
|
|
116
|
-
throw new Error('Failed to excute the `tsc` command, please check if `typescript` is installed correctly in the current directory.');
|
|
125
|
+
currentDirectory = path.dirname(currentDirectory);
|
|
117
126
|
}
|
|
118
127
|
|
|
119
|
-
|
|
128
|
+
throw new Error('Failed to excute the `tsc` command, please check if `typescript` is installed correctly in the current directory.');
|
|
120
129
|
};
|
|
121
130
|
|
|
122
131
|
exports.getTscBinPath = getTscBinPath;
|
package/package.json
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"modern",
|
|
12
12
|
"modern.js"
|
|
13
13
|
],
|
|
14
|
-
"version": "1.21.
|
|
14
|
+
"version": "1.21.2",
|
|
15
15
|
"bin": {
|
|
16
16
|
"modern": "./bin/modern.js"
|
|
17
17
|
},
|
|
@@ -54,18 +54,18 @@
|
|
|
54
54
|
"@babel/runtime": "^7.18.0",
|
|
55
55
|
"@babel/traverse": "^7.18.0",
|
|
56
56
|
"@babel/types": "^7.18.0",
|
|
57
|
-
"@modern-js/babel-compiler": "1.21.
|
|
58
|
-
"@modern-js/babel-preset-module": "1.21.
|
|
59
|
-
"@modern-js/core": "1.21.
|
|
60
|
-
"@modern-js/css-config": "1.21.
|
|
61
|
-
"@modern-js/new-action": "1.21.
|
|
62
|
-
"@modern-js/upgrade": "1.21.
|
|
63
|
-
"@modern-js/plugin": "1.21.
|
|
64
|
-
"@modern-js/plugin-changeset": "1.21.
|
|
65
|
-
"@modern-js/plugin-i18n": "1.21.
|
|
66
|
-
"@modern-js/plugin-jarvis": "1.21.
|
|
67
|
-
"@modern-js/style-compiler": "1.21.
|
|
68
|
-
"@modern-js/utils": "1.21.
|
|
57
|
+
"@modern-js/babel-compiler": "1.21.2",
|
|
58
|
+
"@modern-js/babel-preset-module": "1.21.2",
|
|
59
|
+
"@modern-js/core": "1.21.2",
|
|
60
|
+
"@modern-js/css-config": "1.21.2",
|
|
61
|
+
"@modern-js/new-action": "1.21.2",
|
|
62
|
+
"@modern-js/upgrade": "1.21.2",
|
|
63
|
+
"@modern-js/plugin": "1.21.2",
|
|
64
|
+
"@modern-js/plugin-changeset": "1.21.2",
|
|
65
|
+
"@modern-js/plugin-i18n": "1.21.2",
|
|
66
|
+
"@modern-js/plugin-jarvis": "1.21.2",
|
|
67
|
+
"@modern-js/style-compiler": "1.21.2",
|
|
68
|
+
"@modern-js/utils": "1.21.2",
|
|
69
69
|
"@rollup/plugin-json": "~4.1.0",
|
|
70
70
|
"@speedy-js/speedy-types": "0.13.2-modern.1",
|
|
71
71
|
"@speedy-js/speedy-core": "0.13.2-modern.1",
|
|
@@ -79,8 +79,8 @@
|
|
|
79
79
|
"signal-exit": "^3.0.7"
|
|
80
80
|
},
|
|
81
81
|
"devDependencies": {
|
|
82
|
-
"@scripts/build": "1.21.
|
|
83
|
-
"@scripts/jest-config": "1.21.
|
|
82
|
+
"@scripts/build": "1.21.2",
|
|
83
|
+
"@scripts/jest-config": "1.21.2",
|
|
84
84
|
"@types/babel__core": "^7.1.15",
|
|
85
85
|
"@types/babel__generator": "^7.6.3",
|
|
86
86
|
"@types/babel__traverse": "^7.14.2",
|