Skip to content

Commit 85b8abc

Browse files
author
Andy Hanson
committed
More renaming
1 parent 700b7e7 commit 85b8abc

File tree

8 files changed

+14
-13
lines changed

8 files changed

+14
-13
lines changed

src/harness/fourslash.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2392,7 +2392,7 @@ Actual: ${stringify(fullActual)}`);
23922392
public applyCodeActionFromCompletion(markerName: string, options: FourSlashInterface.VerifyCompletionActionOptions) {
23932393
this.goToMarker(markerName);
23942394

2395-
const actualCompletion = this.getCompletionListAtCaret({ ...ts.defaultOptions, includeCompletionsForExternalModuleExports: true }).entries.find(e =>
2395+
const actualCompletion = this.getCompletionListAtCaret({ ...ts.defaultOptions, includeCompletionsForModuleExports: true }).entries.find(e =>
23962396
e.name === options.name && e.source === options.source);
23972397

23982398
if (!actualCompletion.hasAction) {

src/server/protocol.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2594,7 +2594,7 @@ namespace ts.server.protocol {
25942594
* If enabled, TypeScript will search through all external modules' exports and add them to the completions list.
25952595
* This affects lone identifier completions but not completions on the right hand side of `obj.`.
25962596
*/
2597-
readonly includeCompletionsForExternalModuleExports?: boolean;
2597+
readonly includeCompletionsForModuleExports?: boolean;
25982598
/**
25992599
* If enabled, the completion list will include completions with invalid identifier names.
26002600
* For those entries, The `insertText` and `replacementSpan` properties will be set to change from `.x` property access to `["x"]`.

src/services/completions.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,7 @@ namespace ts.Completions {
479479
{ name, source }: CompletionEntryIdentifier,
480480
allSourceFiles: ReadonlyArray<SourceFile>,
481481
): SymbolCompletion | { type: "request", request: Request } | { type: "none" } {
482-
const completionData = getCompletionData(typeChecker, log, sourceFile, position, allSourceFiles, { includeCompletionsForExternalModuleExports: true, includeCompletionsWithInsertText: true }, compilerOptions.target);
482+
const completionData = getCompletionData(typeChecker, log, sourceFile, position, allSourceFiles, { includeCompletionsForModuleExports: true, includeCompletionsWithInsertText: true }, compilerOptions.target);
483483
if (!completionData) {
484484
return { type: "none" };
485485
}
@@ -746,7 +746,7 @@ namespace ts.Completions {
746746
sourceFile: SourceFile,
747747
position: number,
748748
allSourceFiles: ReadonlyArray<SourceFile>,
749-
options: Pick<Options, "includeCompletionsForExternalModuleExports" | "includeCompletionsWithInsertText">,
749+
options: Pick<Options, "includeCompletionsForModuleExports" | "includeCompletionsWithInsertText">,
750750
target: ScriptTarget,
751751
): CompletionData | Request | undefined {
752752
let start = timestamp();
@@ -1160,7 +1160,7 @@ namespace ts.Completions {
11601160
}
11611161
}
11621162

1163-
if (options.includeCompletionsForExternalModuleExports) {
1163+
if (options.includeCompletionsForModuleExports) {
11641164
getSymbolsFromOtherSourceFileExports(symbols, previousToken && isIdentifier(previousToken) ? previousToken.text : "", target);
11651165
}
11661166
filterGlobalCompletion(symbols);

src/services/services.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1428,7 +1428,7 @@ namespace ts {
14281428
// Convert from deprecated options names to new names
14291429
const fullOptions: Options = {
14301430
...identity<Options>(options), // avoid excess property check
1431-
includeCompletionsForExternalModuleExports: options.includeCompletionsForExternalModuleExports || options.includeExternalModuleExports,
1431+
includeCompletionsForModuleExports: options.includeCompletionsForModuleExports || options.includeExternalModuleExports,
14321432
includeCompletionsWithInsertText: options.includeCompletionsWithInsertText || options.includeInsertTextCompletions,
14331433
};
14341434
synchronizeHostData();

src/services/types.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ namespace ts {
216216

217217
export interface Options {
218218
readonly quote?: "double" | "single";
219-
readonly includeCompletionsForExternalModuleExports?: boolean;
219+
readonly includeCompletionsForModuleExports?: boolean;
220220
readonly includeCompletionsWithInsertText?: boolean;
221221
}
222222
/* @internal */
@@ -339,7 +339,7 @@ namespace ts {
339339

340340
/** @deprecated Use Options */
341341
export interface GetCompletionsAtPositionOptions extends Options {
342-
/** @deprecated Use includeCompletionsForExternalModuleExports */
342+
/** @deprecated Use includeCompletionsForModuleExports */
343343
includeExternalModuleExports?: boolean;
344344
/** @deprecated Use includeCompletionsWithInsertText */
345345
includeInsertTextCompletions?: boolean;

tests/baselines/reference/api/tsserverlibrary.d.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4052,7 +4052,7 @@ declare namespace ts {
40524052
}
40534053
interface Options {
40544054
readonly quote?: "double" | "single";
4055-
readonly includeCompletionsForExternalModuleExports?: boolean;
4055+
readonly includeCompletionsForModuleExports?: boolean;
40564056
readonly includeCompletionsWithInsertText?: boolean;
40574057
}
40584058
interface LanguageService {
@@ -4126,7 +4126,7 @@ declare namespace ts {
41264126
type OrganizeImportsScope = CombinedCodeFixScope;
41274127
/** @deprecated Use Options */
41284128
interface GetCompletionsAtPositionOptions extends Options {
4129-
/** @deprecated Use includeCompletionsForExternalModuleExports */
4129+
/** @deprecated Use includeCompletionsForModuleExports */
41304130
includeExternalModuleExports?: boolean;
41314131
/** @deprecated Use includeCompletionsWithInsertText */
41324132
includeInsertTextCompletions?: boolean;
@@ -7054,7 +7054,7 @@ declare namespace ts.server.protocol {
70547054
* If enabled, TypeScript will search through all external modules' exports and add them to the completions list.
70557055
* This affects lone identifier completions but not completions on the right hand side of `obj.`.
70567056
*/
7057-
readonly includeCompletionsForExternalModuleExports?: boolean;
7057+
readonly includeCompletionsForModuleExports?: boolean;
70587058
/**
70597059
* If enabled, the completion list will include completions with invalid identifier names.
70607060
* For those entries, The `insertText` and `replacementSpan` properties will be set to change from `.x` property access to `["x"]`.

tests/baselines/reference/api/typescript.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4304,7 +4304,7 @@ declare namespace ts {
43044304
}
43054305
interface Options {
43064306
readonly quote?: "double" | "single";
4307-
readonly includeCompletionsForExternalModuleExports?: boolean;
4307+
readonly includeCompletionsForModuleExports?: boolean;
43084308
readonly includeCompletionsWithInsertText?: boolean;
43094309
}
43104310
interface LanguageService {
@@ -4378,7 +4378,7 @@ declare namespace ts {
43784378
type OrganizeImportsScope = CombinedCodeFixScope;
43794379
/** @deprecated Use Options */
43804380
interface GetCompletionsAtPositionOptions extends Options {
4381-
/** @deprecated Use includeCompletionsForExternalModuleExports */
4381+
/** @deprecated Use includeCompletionsForModuleExports */
43824382
includeExternalModuleExports?: boolean;
43834383
/** @deprecated Use includeCompletionsWithInsertText */
43844384
includeInsertTextCompletions?: boolean;

tests/cases/fourslash/fourslash.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -524,6 +524,7 @@ declare namespace FourSlashInterface {
524524
}
525525
interface Options {
526526
quote?: "double" | "single";
527+
includeCompletionsForModuleExports?: boolean;
527528
includeInsertTextCompletions?: boolean;
528529
}
529530
interface CompletionsAtOptions extends Options {

0 commit comments

Comments
 (0)