typescript 4.9.1-beta → 5.0.0-dev.20221101
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/cs/diagnosticMessages.generated.json +6 -0
- package/lib/de/diagnosticMessages.generated.json +6 -0
- package/lib/es/diagnosticMessages.generated.json +6 -0
- package/lib/fr/diagnosticMessages.generated.json +6 -0
- package/lib/it/diagnosticMessages.generated.json +6 -0
- package/lib/ja/diagnosticMessages.generated.json +6 -0
- package/lib/ko/diagnosticMessages.generated.json +6 -0
- package/lib/lib.dom.d.ts +111 -14
- package/lib/lib.dom.iterable.d.ts +6 -2
- package/lib/lib.es2015.symbol.wellknown.d.ts +3 -3
- package/lib/lib.es5.d.ts +3 -2
- package/lib/lib.webworker.d.ts +193 -6
- package/lib/lib.webworker.iterable.d.ts +10 -2
- package/lib/pl/diagnosticMessages.generated.json +9 -3
- package/lib/protocol.d.ts +18 -5
- package/lib/pt-br/diagnosticMessages.generated.json +6 -0
- package/lib/ru/diagnosticMessages.generated.json +6 -0
- package/lib/tr/diagnosticMessages.generated.json +9 -0
- package/lib/tsc.js +532 -291
- package/lib/tsserver.js +1005 -479
- package/lib/tsserverlibrary.d.ts +28 -9
- package/lib/tsserverlibrary.js +1002 -479
- package/lib/typescript.d.ts +10 -3
- package/lib/typescript.js +931 -429
- package/lib/typescriptServices.d.ts +10 -3
- package/lib/typescriptServices.js +931 -429
- package/lib/typingsInstaller.js +655 -367
- package/lib/zh-cn/diagnosticMessages.generated.json +6 -0
- package/lib/zh-tw/diagnosticMessages.generated.json +6 -0
- package/package.json +6 -7
package/lib/tsserverlibrary.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ and limitations under the License.
|
|
|
14
14
|
***************************************************************************** */
|
|
15
15
|
|
|
16
16
|
declare namespace ts {
|
|
17
|
-
const versionMajorMinor = "
|
|
17
|
+
const versionMajorMinor = "5.0";
|
|
18
18
|
/** The version of the TypeScript compiler release */
|
|
19
19
|
const version: string;
|
|
20
20
|
/**
|
|
@@ -5399,9 +5399,9 @@ declare namespace ts {
|
|
|
5399
5399
|
/** If provided, called with Diagnostic message that informs about change in watch status */
|
|
5400
5400
|
onWatchStatusChange?(diagnostic: Diagnostic, newLine: string, options: CompilerOptions, errorCount?: number): void;
|
|
5401
5401
|
/** Used to watch changes in source files, missing files needed to update the program or config file */
|
|
5402
|
-
watchFile(path: string, callback: FileWatcherCallback, pollingInterval?: number, options?:
|
|
5402
|
+
watchFile(path: string, callback: FileWatcherCallback, pollingInterval?: number, options?: WatchOptions): FileWatcher;
|
|
5403
5403
|
/** Used to watch resolved module's failed lookup locations, config file specs, type roots where auto type reference directives are added */
|
|
5404
|
-
watchDirectory(path: string, callback: DirectoryWatcherCallback, recursive?: boolean, options?:
|
|
5404
|
+
watchDirectory(path: string, callback: DirectoryWatcherCallback, recursive?: boolean, options?: WatchOptions): FileWatcher;
|
|
5405
5405
|
/** If provided, will be used to set delayed compilation, so that multiple changes in short span are compiled together */
|
|
5406
5406
|
setTimeout?(callback: (...args: any[]) => void, ms: number, ...args: any[]): any;
|
|
5407
5407
|
/** If provided, will be used to reset existing delayed compilation */
|
|
@@ -6032,8 +6032,15 @@ declare namespace ts {
|
|
|
6032
6032
|
type: "file";
|
|
6033
6033
|
fileName: string;
|
|
6034
6034
|
}
|
|
6035
|
+
enum OrganizeImportsMode {
|
|
6036
|
+
All = "All",
|
|
6037
|
+
SortAndCombine = "SortAndCombine",
|
|
6038
|
+
RemoveUnused = "RemoveUnused"
|
|
6039
|
+
}
|
|
6035
6040
|
interface OrganizeImportsArgs extends CombinedCodeFixScope {
|
|
6041
|
+
/** @deprecated Use `mode` instead */
|
|
6036
6042
|
skipDestructiveCodeActions?: boolean;
|
|
6043
|
+
mode?: OrganizeImportsMode;
|
|
6037
6044
|
}
|
|
6038
6045
|
type CompletionsTriggerCharacter = "." | '"' | "'" | "`" | "/" | "@" | "<" | "#" | " ";
|
|
6039
6046
|
enum CompletionTriggerKind {
|
|
@@ -7616,9 +7623,16 @@ declare namespace ts.server.protocol {
|
|
|
7616
7623
|
arguments: OrganizeImportsRequestArgs;
|
|
7617
7624
|
}
|
|
7618
7625
|
type OrganizeImportsScope = GetCombinedCodeFixScope;
|
|
7626
|
+
enum OrganizeImportsMode {
|
|
7627
|
+
All = "All",
|
|
7628
|
+
SortAndCombine = "SortAndCombine",
|
|
7629
|
+
RemoveUnused = "RemoveUnused"
|
|
7630
|
+
}
|
|
7619
7631
|
interface OrganizeImportsRequestArgs {
|
|
7620
7632
|
scope: OrganizeImportsScope;
|
|
7633
|
+
/** @deprecated Use `mode` instead */
|
|
7621
7634
|
skipDestructiveCodeActions?: boolean;
|
|
7635
|
+
mode?: OrganizeImportsMode;
|
|
7622
7636
|
}
|
|
7623
7637
|
interface OrganizeImportsResponse extends Response {
|
|
7624
7638
|
body: readonly FileCodeEdits[];
|
|
@@ -7968,12 +7982,14 @@ declare namespace ts.server.protocol {
|
|
|
7968
7982
|
command: CommandTypes.References;
|
|
7969
7983
|
}
|
|
7970
7984
|
interface ReferencesResponseItem extends FileSpanWithContext {
|
|
7971
|
-
/**
|
|
7972
|
-
*
|
|
7973
|
-
*
|
|
7974
|
-
* loaded the referencing files).
|
|
7985
|
+
/**
|
|
7986
|
+
* Text of line containing the reference. Including this
|
|
7987
|
+
* with the response avoids latency of editor loading files
|
|
7988
|
+
* to show text of reference line (the server already has loaded the referencing files).
|
|
7989
|
+
*
|
|
7990
|
+
* If {@link UserPreferences.disableLineTextInReferences} is enabled, the property won't be filled
|
|
7975
7991
|
*/
|
|
7976
|
-
lineText
|
|
7992
|
+
lineText?: string;
|
|
7977
7993
|
/**
|
|
7978
7994
|
* True if reference is a write location, false otherwise.
|
|
7979
7995
|
*/
|
|
@@ -9819,6 +9835,10 @@ declare namespace ts.server.protocol {
|
|
|
9819
9835
|
readonly includeInlayFunctionLikeReturnTypeHints?: boolean;
|
|
9820
9836
|
readonly includeInlayEnumMemberValueHints?: boolean;
|
|
9821
9837
|
readonly autoImportFileExcludePatterns?: string[];
|
|
9838
|
+
/**
|
|
9839
|
+
* Indicates whether {@link ReferencesResponseItem.lineText} is supported.
|
|
9840
|
+
*/
|
|
9841
|
+
readonly disableLineTextInReferences?: boolean;
|
|
9822
9842
|
}
|
|
9823
9843
|
interface CompilerOptions {
|
|
9824
9844
|
allowJs?: boolean;
|
|
@@ -10070,7 +10090,6 @@ declare namespace ts.server {
|
|
|
10070
10090
|
private externalFiles;
|
|
10071
10091
|
private missingFilesMap;
|
|
10072
10092
|
private generatedFilesMap;
|
|
10073
|
-
private plugins;
|
|
10074
10093
|
protected languageService: LanguageService;
|
|
10075
10094
|
languageServiceEnabled: boolean;
|
|
10076
10095
|
readonly trace?: (s: string) => void;
|