Skip to content

Commit 15e744f

Browse files
committed
chore: remove outdated completion cache logic
#502
1 parent c75f098 commit 15e744f

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

packages/shared/src/ts.ts

+2-9
Original file line numberDiff line numberDiff line change
@@ -55,16 +55,9 @@ export function getTsCompletions(ts: typeof import('typescript/lib/tsserverlibra
5555

5656
export function createTsLanguageService(
5757
ts: typeof import('typescript/lib/tsserverlibrary'),
58-
_host: ts.LanguageServiceHost,
58+
host: ts.LanguageServiceHost,
5959
) {
60-
// @ts-ignore
61-
const importSuggestionsCache = ts.Completions?.createImportSuggestionsForFileCache?.();
62-
const host = {
63-
..._host,
64-
// @ts-ignore
65-
// TODO: crash on 'addListener' from 'node:process', reuse because TS has same problem
66-
getImportSuggestionsCache: () => importSuggestionsCache,
67-
};
60+
// TODO: new cache logic https://github.com/microsoft/TypeScript/blob/4c0a51e14b67460b47bdcebea6b70270a83a243e/src/server/project.ts#L258
6861
return ts.createLanguageService(host);
6962
}
7063

0 commit comments

Comments
 (0)