@volar/typescript 1.4.0 → 1.4.1-patch.1
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/out/getProgram.js +3 -12
- package/package.json +3 -4
package/out/getProgram.js
CHANGED
|
@@ -120,18 +120,9 @@ function getProgram(ts, core, ls) {
|
|
|
120
120
|
}
|
|
121
121
|
}
|
|
122
122
|
else {
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|| fileName.endsWith('.jsx')
|
|
127
|
-
|| fileName.endsWith('.tsx')
|
|
128
|
-
|| fileName.endsWith('.mjs')
|
|
129
|
-
|| fileName.endsWith('.mts')
|
|
130
|
-
|| fileName.endsWith('.cjs')
|
|
131
|
-
|| fileName.endsWith('.cts')) {
|
|
132
|
-
scriptTarget = ts.ScriptTarget.Latest;
|
|
133
|
-
}
|
|
134
|
-
file = ts.createSourceFile(fileName, docText, scriptTarget);
|
|
123
|
+
file = ts.createSourceFile(fileName, docText, ts.ScriptTarget.Latest, undefined, ts.ScriptKind.Deferred);
|
|
124
|
+
file.parseDiagnostics = []; // not important
|
|
125
|
+
file.resolvedPath = fileName; // fix https://github.com/vuejs/language-tools/issues/2622 for TS 5.0
|
|
135
126
|
}
|
|
136
127
|
}
|
|
137
128
|
const newDiagnostic = {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@volar/typescript",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.1-patch.1",
|
|
4
4
|
"main": "out/index.js",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"files": [
|
|
@@ -13,10 +13,9 @@
|
|
|
13
13
|
"directory": "packages/typescript"
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@volar/language-core": "1.4.
|
|
16
|
+
"@volar/language-core": "1.4.1"
|
|
17
17
|
},
|
|
18
18
|
"peerDependencies": {
|
|
19
19
|
"typescript": "*"
|
|
20
|
-
}
|
|
21
|
-
"gitHead": "9bf14ef0d08c53f9ae32cf538d9748fa91cc4ab7"
|
|
20
|
+
}
|
|
22
21
|
}
|