Add property for unchecked completions

This commit is contained in:
Ben Lichtman 2020-01-07 10:59:19 -08:00
parent 8ed92dcecd
commit 1bc387938a
3 changed files with 8 additions and 1 deletions

View File

@ -2086,6 +2086,11 @@ namespace ts.server.protocol {
* Then either that enum/class or a namespace containing it will be the recommended symbol.
*/
isRecommended?: true;
/**
* If true, this completion was generated from traversing the name table of an unchecked JS file,
* and therefore may not be accurate.
*/
isUncheckedCompletion?: true;
}
/**

View File

@ -310,7 +310,8 @@ namespace ts.Completions {
name: realName,
kind: ScriptElementKind.warning,
kindModifiers: "",
sortText: SortText.JavascriptIdentifiers
sortText: SortText.JavascriptIdentifiers,
isUncheckedCompletion: true
});
}
});

View File

@ -988,6 +988,7 @@ namespace ts {
hasAction?: true;
source?: string;
isRecommended?: true;
isUncheckedCompletion?: true;
}
export interface CompletionEntryDetails {