typescript 4.7.0-dev.20220329 → 4.7.0-dev.20220401
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/lib/protocol.d.ts +30 -0
- package/lib/tsc.js +90 -40
- package/lib/tsserver.js +542 -240
- package/lib/tsserverlibrary.d.ts +39 -1
- package/lib/tsserverlibrary.js +542 -240
- package/lib/typescript.d.ts +9 -1
- package/lib/typescript.js +524 -238
- package/lib/typescriptServices.d.ts +9 -1
- package/lib/typescriptServices.js +524 -238
- package/lib/typingsInstaller.js +97 -42
- package/package.json +1 -1
package/lib/tsserverlibrary.d.ts
CHANGED
|
@@ -2977,6 +2977,7 @@ declare namespace ts {
|
|
|
2977
2977
|
maxNodeModuleJsDepth?: number;
|
|
2978
2978
|
module?: ModuleKind;
|
|
2979
2979
|
moduleResolution?: ModuleResolutionKind;
|
|
2980
|
+
moduleSuffixes?: string[];
|
|
2980
2981
|
moduleDetection?: ModuleDetectionKind;
|
|
2981
2982
|
newLine?: NewLineKind;
|
|
2982
2983
|
noEmit?: boolean;
|
|
@@ -3163,7 +3164,7 @@ declare namespace ts {
|
|
|
3163
3164
|
realpath?(path: string): string;
|
|
3164
3165
|
getCurrentDirectory?(): string;
|
|
3165
3166
|
getDirectories?(path: string): string[];
|
|
3166
|
-
useCaseSensitiveFileNames?: boolean | (() => boolean);
|
|
3167
|
+
useCaseSensitiveFileNames?: boolean | (() => boolean) | undefined;
|
|
3167
3168
|
}
|
|
3168
3169
|
/**
|
|
3169
3170
|
* Used by services to specify the minimum host area required to set up source files under any compilation settings
|
|
@@ -4099,6 +4100,8 @@ declare namespace ts {
|
|
|
4099
4100
|
readonly includeAutomaticOptionalChainCompletions?: boolean;
|
|
4100
4101
|
readonly includeCompletionsWithInsertText?: boolean;
|
|
4101
4102
|
readonly includeCompletionsWithClassMemberSnippets?: boolean;
|
|
4103
|
+
readonly includeCompletionsWithObjectLiteralMethodSnippets?: boolean;
|
|
4104
|
+
readonly useLabelDetailsInCompletionEntries?: boolean;
|
|
4102
4105
|
readonly allowIncompleteCompletions?: boolean;
|
|
4103
4106
|
readonly importModuleSpecifierPreference?: "shortest" | "project-relative" | "relative" | "non-relative";
|
|
4104
4107
|
/** Determines whether we import `foo/index.ts` as "foo", "foo/index", or "foo/index.js" */
|
|
@@ -6484,6 +6487,7 @@ declare namespace ts {
|
|
|
6484
6487
|
hasAction?: true;
|
|
6485
6488
|
source?: string;
|
|
6486
6489
|
sourceDisplay?: SymbolDisplayPart[];
|
|
6490
|
+
labelDetails?: CompletionEntryLabelDetails;
|
|
6487
6491
|
isRecommended?: true;
|
|
6488
6492
|
isFromUncheckedFile?: true;
|
|
6489
6493
|
isPackageJsonImport?: true;
|
|
@@ -6498,6 +6502,10 @@ declare namespace ts {
|
|
|
6498
6502
|
*/
|
|
6499
6503
|
data?: CompletionEntryData;
|
|
6500
6504
|
}
|
|
6505
|
+
interface CompletionEntryLabelDetails {
|
|
6506
|
+
detail?: string;
|
|
6507
|
+
description?: string;
|
|
6508
|
+
}
|
|
6501
6509
|
interface CompletionEntryDetails {
|
|
6502
6510
|
name: string;
|
|
6503
6511
|
kind: ScriptElementKind;
|
|
@@ -8707,6 +8715,10 @@ declare namespace ts.server.protocol {
|
|
|
8707
8715
|
* Human-readable description of the `source`.
|
|
8708
8716
|
*/
|
|
8709
8717
|
sourceDisplay?: SymbolDisplayPart[];
|
|
8718
|
+
/**
|
|
8719
|
+
* Additional details for the label.
|
|
8720
|
+
*/
|
|
8721
|
+
labelDetails?: CompletionEntryLabelDetails;
|
|
8710
8722
|
/**
|
|
8711
8723
|
* If true, this completion should be highlighted as recommended. There will only be one of these.
|
|
8712
8724
|
* This will be set when we know the user should write an expression with a certain type and that type is an enum or constructable class.
|
|
@@ -8735,6 +8747,20 @@ declare namespace ts.server.protocol {
|
|
|
8735
8747
|
*/
|
|
8736
8748
|
data?: unknown;
|
|
8737
8749
|
}
|
|
8750
|
+
interface CompletionEntryLabelDetails {
|
|
8751
|
+
/**
|
|
8752
|
+
* An optional string which is rendered less prominently directly after
|
|
8753
|
+
* {@link CompletionEntry.name name}, without any spacing. Should be
|
|
8754
|
+
* used for function signatures or type annotations.
|
|
8755
|
+
*/
|
|
8756
|
+
detail?: string;
|
|
8757
|
+
/**
|
|
8758
|
+
* An optional string which is rendered less prominently after
|
|
8759
|
+
* {@link CompletionEntryLabelDetails.detail}. Should be used for fully qualified
|
|
8760
|
+
* names or file path.
|
|
8761
|
+
*/
|
|
8762
|
+
description?: string;
|
|
8763
|
+
}
|
|
8738
8764
|
/**
|
|
8739
8765
|
* Additional completion entry details, available on demand
|
|
8740
8766
|
*/
|
|
@@ -9628,6 +9654,18 @@ declare namespace ts.server.protocol {
|
|
|
9628
9654
|
* `class A { foo }`.
|
|
9629
9655
|
*/
|
|
9630
9656
|
readonly includeCompletionsWithClassMemberSnippets?: boolean;
|
|
9657
|
+
/**
|
|
9658
|
+
* If enabled, object literal methods will have a method declaration completion entry in addition
|
|
9659
|
+
* to the regular completion entry containing just the method name.
|
|
9660
|
+
* E.g., `const objectLiteral: T = { f| }` could be completed to `const objectLiteral: T = { foo(): void {} }`,
|
|
9661
|
+
* in addition to `const objectLiteral: T = { foo }`.
|
|
9662
|
+
*/
|
|
9663
|
+
readonly includeCompletionsWithObjectLiteralMethodSnippets?: boolean;
|
|
9664
|
+
/**
|
|
9665
|
+
* Indicates whether {@link CompletionEntry.labelDetails completion entry label details} are supported.
|
|
9666
|
+
* If not, contents of `labelDetails` may be included in the {@link CompletionEntry.name} property.
|
|
9667
|
+
*/
|
|
9668
|
+
readonly useLabelDetailsInCompletionEntries?: boolean;
|
|
9631
9669
|
readonly allowIncompleteCompletions?: boolean;
|
|
9632
9670
|
readonly importModuleSpecifierPreference?: "shortest" | "project-relative" | "relative" | "non-relative";
|
|
9633
9671
|
/** Determines whether we import `foo/index.ts` as "foo", "foo/index", or "foo/index.js" */
|