vue-tsc 3.3.9 → 3.3.11
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/index.js +14 -14
- package/package.json +3 -3
package/index.js
CHANGED
|
@@ -38,35 +38,35 @@ const runTsc_1 = require("@volar/typescript/lib/quickstart/runTsc");
|
|
|
38
38
|
const core = __importStar(require("@vue/language-core"));
|
|
39
39
|
const path = __importStar(require("node:path"));
|
|
40
40
|
const windowsPathRE = /\\/g;
|
|
41
|
+
const retryToken = new Error('[Vue] Extensions changed');
|
|
41
42
|
function run(tscPath) {
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
const main = () => (0, runTsc_1.runTsc)(resolveTscPath(tscPath), runExtensions, (ts, options) => {
|
|
43
|
+
const runExtensions = new Set(['vue']);
|
|
44
|
+
const main = () => (0, runTsc_1.runTsc)(resolveTscPath(tscPath), [...runExtensions], (ts, options) => {
|
|
45
45
|
const { configFilePath } = options.options;
|
|
46
46
|
const vueOptions = typeof configFilePath === 'string'
|
|
47
47
|
? core.createParsedCommandLine(ts, ts.sys, configFilePath.replace(windowsPathRE, '/')).vueOptions
|
|
48
48
|
: core.createParsedCommandLineByJson(ts, ts.sys, (options.host ?? ts.sys).getCurrentDirectory(), {})
|
|
49
49
|
.vueOptions;
|
|
50
50
|
const allExtensions = core.getAllExtensions(vueOptions);
|
|
51
|
-
if (
|
|
52
|
-
&& runExtensions.every(ext => allExtensions.includes(ext))) {
|
|
51
|
+
if (allExtensions.every(ext => runExtensions.has(ext))) {
|
|
53
52
|
const vueLanguagePlugin = core.createVueLanguagePlugin(ts, options.options, vueOptions, id => id);
|
|
54
53
|
return { languagePlugins: [vueLanguagePlugin] };
|
|
55
54
|
}
|
|
56
55
|
else {
|
|
57
|
-
|
|
58
|
-
|
|
56
|
+
for (const ext of allExtensions) {
|
|
57
|
+
runExtensions.add(ext);
|
|
58
|
+
}
|
|
59
|
+
throw retryToken;
|
|
59
60
|
}
|
|
60
61
|
});
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
}
|
|
64
|
-
catch (err) {
|
|
65
|
-
if (err === extensionsChangedException) {
|
|
62
|
+
while (true) {
|
|
63
|
+
try {
|
|
66
64
|
return main();
|
|
67
65
|
}
|
|
68
|
-
|
|
69
|
-
|
|
66
|
+
catch (err) {
|
|
67
|
+
if (err !== retryToken) {
|
|
68
|
+
throw err;
|
|
69
|
+
}
|
|
70
70
|
}
|
|
71
71
|
}
|
|
72
72
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vue-tsc",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.11",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"files": [
|
|
6
6
|
"bin",
|
|
@@ -21,11 +21,11 @@
|
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"@volar/typescript": "2.4.28",
|
|
24
|
-
"@vue/language-core": "3.3.
|
|
24
|
+
"@vue/language-core": "3.3.11"
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
27
|
"@types/node": "^26.0.1",
|
|
28
28
|
"typescript": "latest"
|
|
29
29
|
},
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "f521b39b402ebaaa9ee70faf5a60a895544ed9e9"
|
|
31
31
|
}
|