Skip to content

Commit 07f3bd5

Browse files
committed
perf: fix always check .ts fileExists on update
1 parent a9761a0 commit 07f3bd5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/vue-language-core/src/lsContext.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ export function createLanguageContext(
161161

162162
// .ts / .js / .d.ts / .json ...
163163
for (const tsFileVersion of tsFileVersions) {
164-
if (!vueFileNames.has(tsFileVersion[0]) && !host.fileExists?.(tsFileVersion[0])) {
164+
if (!tsFileNames.has(tsFileVersion[0]) && !host.getScriptSnapshot(tsFileVersion[0])) {
165165
// delete
166166
tsFileVersions.delete(tsFileVersion[0]);
167167
tsFileUpdated = true;

0 commit comments

Comments
 (0)