mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-06-27 04:48:33 -05:00
Updated LKG
This commit is contained in:
70
bin/lib.core.es6.d.ts
vendored
70
bin/lib.core.es6.d.ts
vendored
@@ -1237,11 +1237,41 @@ interface SymbolConstructor {
|
||||
isConcatSpreadable: symbol;
|
||||
|
||||
/**
|
||||
* A method that returns the default iterator for an object.Called by the semantics of the
|
||||
* A method that returns the default iterator for an object. Called by the semantics of the
|
||||
* for-of statement.
|
||||
*/
|
||||
iterator: symbol;
|
||||
|
||||
/**
|
||||
* A regular expression method that matches the regular expression against a string. Called
|
||||
* by the String.prototype.match method.
|
||||
*/
|
||||
match: symbol;
|
||||
|
||||
/**
|
||||
* A regular expression method that replaces matched substrings of a string. Called by the
|
||||
* String.prototype.replace method.
|
||||
*/
|
||||
replace: symbol;
|
||||
|
||||
/**
|
||||
* A regular expression method that returns the index within a string that matches the
|
||||
* regular expression. Called by the String.prototype.search method.
|
||||
*/
|
||||
search: symbol;
|
||||
|
||||
/**
|
||||
* A function valued property that is the constructor function that is used to create
|
||||
* derived objects.
|
||||
*/
|
||||
species: symbol;
|
||||
|
||||
/**
|
||||
* A regular expression method that splits a string at the indices that match the regular
|
||||
* expression. Called by the String.prototype.split method.
|
||||
*/
|
||||
split: symbol;
|
||||
|
||||
/**
|
||||
* A method that converts an object to a corresponding primitive value.Called by the ToPrimitive
|
||||
* abstract operation.
|
||||
@@ -4728,6 +4758,16 @@ declare module Reflect {
|
||||
function setPrototypeOf(target: any, proto: any): boolean;
|
||||
}
|
||||
|
||||
interface PromiseLike<T> {
|
||||
/**
|
||||
* Attaches callbacks for the resolution and/or rejection of the Promise.
|
||||
* @param onfulfilled The callback to execute when the Promise is resolved.
|
||||
* @param onrejected The callback to execute when the Promise is rejected.
|
||||
* @returns A Promise for the completion of which ever callback is executed.
|
||||
*/
|
||||
then<TResult>(onfulfilled?: (value: T) => TResult | PromiseLike<TResult>, onrejected?: (reason: any) => TResult | PromiseLike<TResult>): PromiseLike<TResult>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents the completion of an asynchronous operation
|
||||
*/
|
||||
@@ -4738,14 +4778,16 @@ interface Promise<T> {
|
||||
* @param onrejected The callback to execute when the Promise is rejected.
|
||||
* @returns A Promise for the completion of which ever callback is executed.
|
||||
*/
|
||||
then<TResult>(onfulfilled?: (value: T) => TResult | Promise<TResult>, onrejected?: (reason: any) => TResult | Promise<TResult>): Promise<TResult>;
|
||||
then<TResult>(onfulfilled?: (value: T) => TResult | PromiseLike<TResult>, onrejected?: (reason: any) => TResult | PromiseLike<TResult>): Promise<TResult>;
|
||||
|
||||
/**
|
||||
* Attaches a callback for only the rejection of the Promise.
|
||||
* @param onrejected The callback to execute when the Promise is rejected.
|
||||
* @returns A Promise for the completion of the callback.
|
||||
*/
|
||||
catch(onrejected?: (reason: any) => T | Promise<T>): Promise<T>;
|
||||
catch(onrejected?: (reason: any) => T | PromiseLike<T>): Promise<T>;
|
||||
|
||||
[Symbol.toStringTag]: string;
|
||||
}
|
||||
|
||||
interface PromiseConstructor {
|
||||
@@ -4756,13 +4798,11 @@ interface PromiseConstructor {
|
||||
|
||||
/**
|
||||
* Creates a new Promise.
|
||||
* @param init A callback used to initialize the promise. This callback is passed two arguments:
|
||||
* @param executor A callback used to initialize the promise. This callback is passed two arguments:
|
||||
* a resolve callback used resolve the promise with a value or the result of another promise,
|
||||
* and a reject callback used to reject the promise with a provided reason or error.
|
||||
*/
|
||||
new <T>(init: (resolve: (value?: T | Promise<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;
|
||||
|
||||
<T>(init: (resolve: (value?: T | Promise<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;
|
||||
new <T>(executor: (resolve: (value?: T | PromiseLike<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;
|
||||
|
||||
/**
|
||||
* Creates a Promise that is resolved with an array of results when all of the provided Promises
|
||||
@@ -4770,15 +4810,7 @@ interface PromiseConstructor {
|
||||
* @param values An array of Promises.
|
||||
* @returns A new Promise.
|
||||
*/
|
||||
all<T>(values: (T | Promise<T>)[]): Promise<T[]>;
|
||||
|
||||
/**
|
||||
* Creates a Promise that is resolved with an array of results when all of the provided Promises
|
||||
* resolve, or rejected when any Promise is rejected.
|
||||
* @param values An array of values.
|
||||
* @returns A new Promise.
|
||||
*/
|
||||
all(values: Promise<void>[]): Promise<void>;
|
||||
all<T>(values: Iterable<T | PromiseLike<T>>): Promise<T[]>;
|
||||
|
||||
/**
|
||||
* Creates a Promise that is resolved or rejected when any of the provided Promises are resolved
|
||||
@@ -4786,7 +4818,7 @@ interface PromiseConstructor {
|
||||
* @param values An array of Promises.
|
||||
* @returns A new Promise.
|
||||
*/
|
||||
race<T>(values: (T | Promise<T>)[]): Promise<T>;
|
||||
race<T>(values: Iterable<T | PromiseLike<T>>): Promise<T>;
|
||||
|
||||
/**
|
||||
* Creates a new rejected promise for the provided reason.
|
||||
@@ -4807,13 +4839,15 @@ interface PromiseConstructor {
|
||||
* @param value A promise.
|
||||
* @returns A promise whose internal state matches the provided promise.
|
||||
*/
|
||||
resolve<T>(value: T | Promise<T>): Promise<T>;
|
||||
resolve<T>(value: T | PromiseLike<T>): Promise<T>;
|
||||
|
||||
/**
|
||||
* Creates a new resolved promise .
|
||||
* @returns A resolved promise.
|
||||
*/
|
||||
resolve(): Promise<void>;
|
||||
|
||||
[Symbol.species]: Function;
|
||||
}
|
||||
|
||||
declare var Promise: PromiseConstructor;
|
||||
|
||||
70
bin/lib.es6.d.ts
vendored
70
bin/lib.es6.d.ts
vendored
@@ -1237,11 +1237,41 @@ interface SymbolConstructor {
|
||||
isConcatSpreadable: symbol;
|
||||
|
||||
/**
|
||||
* A method that returns the default iterator for an object.Called by the semantics of the
|
||||
* A method that returns the default iterator for an object. Called by the semantics of the
|
||||
* for-of statement.
|
||||
*/
|
||||
iterator: symbol;
|
||||
|
||||
/**
|
||||
* A regular expression method that matches the regular expression against a string. Called
|
||||
* by the String.prototype.match method.
|
||||
*/
|
||||
match: symbol;
|
||||
|
||||
/**
|
||||
* A regular expression method that replaces matched substrings of a string. Called by the
|
||||
* String.prototype.replace method.
|
||||
*/
|
||||
replace: symbol;
|
||||
|
||||
/**
|
||||
* A regular expression method that returns the index within a string that matches the
|
||||
* regular expression. Called by the String.prototype.search method.
|
||||
*/
|
||||
search: symbol;
|
||||
|
||||
/**
|
||||
* A function valued property that is the constructor function that is used to create
|
||||
* derived objects.
|
||||
*/
|
||||
species: symbol;
|
||||
|
||||
/**
|
||||
* A regular expression method that splits a string at the indices that match the regular
|
||||
* expression. Called by the String.prototype.split method.
|
||||
*/
|
||||
split: symbol;
|
||||
|
||||
/**
|
||||
* A method that converts an object to a corresponding primitive value.Called by the ToPrimitive
|
||||
* abstract operation.
|
||||
@@ -4728,6 +4758,16 @@ declare module Reflect {
|
||||
function setPrototypeOf(target: any, proto: any): boolean;
|
||||
}
|
||||
|
||||
interface PromiseLike<T> {
|
||||
/**
|
||||
* Attaches callbacks for the resolution and/or rejection of the Promise.
|
||||
* @param onfulfilled The callback to execute when the Promise is resolved.
|
||||
* @param onrejected The callback to execute when the Promise is rejected.
|
||||
* @returns A Promise for the completion of which ever callback is executed.
|
||||
*/
|
||||
then<TResult>(onfulfilled?: (value: T) => TResult | PromiseLike<TResult>, onrejected?: (reason: any) => TResult | PromiseLike<TResult>): PromiseLike<TResult>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents the completion of an asynchronous operation
|
||||
*/
|
||||
@@ -4738,14 +4778,16 @@ interface Promise<T> {
|
||||
* @param onrejected The callback to execute when the Promise is rejected.
|
||||
* @returns A Promise for the completion of which ever callback is executed.
|
||||
*/
|
||||
then<TResult>(onfulfilled?: (value: T) => TResult | Promise<TResult>, onrejected?: (reason: any) => TResult | Promise<TResult>): Promise<TResult>;
|
||||
then<TResult>(onfulfilled?: (value: T) => TResult | PromiseLike<TResult>, onrejected?: (reason: any) => TResult | PromiseLike<TResult>): Promise<TResult>;
|
||||
|
||||
/**
|
||||
* Attaches a callback for only the rejection of the Promise.
|
||||
* @param onrejected The callback to execute when the Promise is rejected.
|
||||
* @returns A Promise for the completion of the callback.
|
||||
*/
|
||||
catch(onrejected?: (reason: any) => T | Promise<T>): Promise<T>;
|
||||
catch(onrejected?: (reason: any) => T | PromiseLike<T>): Promise<T>;
|
||||
|
||||
[Symbol.toStringTag]: string;
|
||||
}
|
||||
|
||||
interface PromiseConstructor {
|
||||
@@ -4756,13 +4798,11 @@ interface PromiseConstructor {
|
||||
|
||||
/**
|
||||
* Creates a new Promise.
|
||||
* @param init A callback used to initialize the promise. This callback is passed two arguments:
|
||||
* @param executor A callback used to initialize the promise. This callback is passed two arguments:
|
||||
* a resolve callback used resolve the promise with a value or the result of another promise,
|
||||
* and a reject callback used to reject the promise with a provided reason or error.
|
||||
*/
|
||||
new <T>(init: (resolve: (value?: T | Promise<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;
|
||||
|
||||
<T>(init: (resolve: (value?: T | Promise<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;
|
||||
new <T>(executor: (resolve: (value?: T | PromiseLike<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;
|
||||
|
||||
/**
|
||||
* Creates a Promise that is resolved with an array of results when all of the provided Promises
|
||||
@@ -4770,15 +4810,7 @@ interface PromiseConstructor {
|
||||
* @param values An array of Promises.
|
||||
* @returns A new Promise.
|
||||
*/
|
||||
all<T>(values: (T | Promise<T>)[]): Promise<T[]>;
|
||||
|
||||
/**
|
||||
* Creates a Promise that is resolved with an array of results when all of the provided Promises
|
||||
* resolve, or rejected when any Promise is rejected.
|
||||
* @param values An array of values.
|
||||
* @returns A new Promise.
|
||||
*/
|
||||
all(values: Promise<void>[]): Promise<void>;
|
||||
all<T>(values: Iterable<T | PromiseLike<T>>): Promise<T[]>;
|
||||
|
||||
/**
|
||||
* Creates a Promise that is resolved or rejected when any of the provided Promises are resolved
|
||||
@@ -4786,7 +4818,7 @@ interface PromiseConstructor {
|
||||
* @param values An array of Promises.
|
||||
* @returns A new Promise.
|
||||
*/
|
||||
race<T>(values: (T | Promise<T>)[]): Promise<T>;
|
||||
race<T>(values: Iterable<T | PromiseLike<T>>): Promise<T>;
|
||||
|
||||
/**
|
||||
* Creates a new rejected promise for the provided reason.
|
||||
@@ -4807,13 +4839,15 @@ interface PromiseConstructor {
|
||||
* @param value A promise.
|
||||
* @returns A promise whose internal state matches the provided promise.
|
||||
*/
|
||||
resolve<T>(value: T | Promise<T>): Promise<T>;
|
||||
resolve<T>(value: T | PromiseLike<T>): Promise<T>;
|
||||
|
||||
/**
|
||||
* Creates a new resolved promise .
|
||||
* @returns A resolved promise.
|
||||
*/
|
||||
resolve(): Promise<void>;
|
||||
|
||||
[Symbol.species]: Function;
|
||||
}
|
||||
|
||||
declare var Promise: PromiseConstructor;
|
||||
|
||||
720
bin/tsc.js
720
bin/tsc.js
File diff suppressed because it is too large
Load Diff
757
bin/tsserver.js
757
bin/tsserver.js
File diff suppressed because it is too large
Load Diff
23
bin/typescript.d.ts
vendored
23
bin/typescript.d.ts
vendored
@@ -756,6 +756,9 @@ declare module "typescript" {
|
||||
getSourceFile(fileName: string): SourceFile;
|
||||
getCurrentDirectory(): string;
|
||||
}
|
||||
interface ParseConfigHost {
|
||||
readDirectory(rootDir: string, extension: string): string[];
|
||||
}
|
||||
interface WriteFileCallback {
|
||||
(fileName: string, data: string, writeByteOrderMark: boolean, onError?: (message: string) => void): void;
|
||||
}
|
||||
@@ -804,6 +807,7 @@ declare module "typescript" {
|
||||
sourceMapFile: string;
|
||||
sourceMapSourceRoot: string;
|
||||
sourceMapSources: string[];
|
||||
sourceMapSourcesContent?: string[];
|
||||
inputSourceFileNames: string[];
|
||||
sourceMapNames?: string[];
|
||||
sourceMapMappings: string;
|
||||
@@ -1082,6 +1086,8 @@ declare module "typescript" {
|
||||
diagnostics?: boolean;
|
||||
emitBOM?: boolean;
|
||||
help?: boolean;
|
||||
inlineSourceMap?: boolean;
|
||||
inlineSources?: boolean;
|
||||
listFiles?: boolean;
|
||||
locale?: string;
|
||||
mapRoot?: string;
|
||||
@@ -1113,6 +1119,7 @@ declare module "typescript" {
|
||||
CommonJS = 1,
|
||||
AMD = 2,
|
||||
UMD = 3,
|
||||
System = 4,
|
||||
}
|
||||
interface LineAndCharacter {
|
||||
line: number;
|
||||
@@ -1236,14 +1243,26 @@ declare module "typescript" {
|
||||
* Read tsconfig.json file
|
||||
* @param fileName The path to the config file
|
||||
*/
|
||||
function readConfigFile(fileName: string): any;
|
||||
function readConfigFile(fileName: string): {
|
||||
config?: any;
|
||||
error?: Diagnostic;
|
||||
};
|
||||
/**
|
||||
* Parse the text of the tsconfig.json file
|
||||
* @param fileName The path to the config file
|
||||
* @param jsonText The text of the config file
|
||||
*/
|
||||
function parseConfigFileText(fileName: string, jsonText: string): {
|
||||
config?: any;
|
||||
error?: Diagnostic;
|
||||
};
|
||||
/**
|
||||
* Parse the contents of a config file (tsconfig.json).
|
||||
* @param json The contents of the config file to parse
|
||||
* @param basePath A root directory to resolve relative path entries in the config
|
||||
* file to. e.g. outDir
|
||||
*/
|
||||
function parseConfigFile(json: any, basePath?: string): ParsedCommandLine;
|
||||
function parseConfigFile(json: any, host: ParseConfigHost, basePath: string): ParsedCommandLine;
|
||||
}
|
||||
declare module "typescript" {
|
||||
/** The version of the language service API */
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
23
bin/typescriptServices.d.ts
vendored
23
bin/typescriptServices.d.ts
vendored
@@ -756,6 +756,9 @@ declare module ts {
|
||||
getSourceFile(fileName: string): SourceFile;
|
||||
getCurrentDirectory(): string;
|
||||
}
|
||||
interface ParseConfigHost {
|
||||
readDirectory(rootDir: string, extension: string): string[];
|
||||
}
|
||||
interface WriteFileCallback {
|
||||
(fileName: string, data: string, writeByteOrderMark: boolean, onError?: (message: string) => void): void;
|
||||
}
|
||||
@@ -804,6 +807,7 @@ declare module ts {
|
||||
sourceMapFile: string;
|
||||
sourceMapSourceRoot: string;
|
||||
sourceMapSources: string[];
|
||||
sourceMapSourcesContent?: string[];
|
||||
inputSourceFileNames: string[];
|
||||
sourceMapNames?: string[];
|
||||
sourceMapMappings: string;
|
||||
@@ -1082,6 +1086,8 @@ declare module ts {
|
||||
diagnostics?: boolean;
|
||||
emitBOM?: boolean;
|
||||
help?: boolean;
|
||||
inlineSourceMap?: boolean;
|
||||
inlineSources?: boolean;
|
||||
listFiles?: boolean;
|
||||
locale?: string;
|
||||
mapRoot?: string;
|
||||
@@ -1113,6 +1119,7 @@ declare module ts {
|
||||
CommonJS = 1,
|
||||
AMD = 2,
|
||||
UMD = 3,
|
||||
System = 4,
|
||||
}
|
||||
interface LineAndCharacter {
|
||||
line: number;
|
||||
@@ -1236,14 +1243,26 @@ declare module ts {
|
||||
* Read tsconfig.json file
|
||||
* @param fileName The path to the config file
|
||||
*/
|
||||
function readConfigFile(fileName: string): any;
|
||||
function readConfigFile(fileName: string): {
|
||||
config?: any;
|
||||
error?: Diagnostic;
|
||||
};
|
||||
/**
|
||||
* Parse the text of the tsconfig.json file
|
||||
* @param fileName The path to the config file
|
||||
* @param jsonText The text of the config file
|
||||
*/
|
||||
function parseConfigFileText(fileName: string, jsonText: string): {
|
||||
config?: any;
|
||||
error?: Diagnostic;
|
||||
};
|
||||
/**
|
||||
* Parse the contents of a config file (tsconfig.json).
|
||||
* @param json The contents of the config file to parse
|
||||
* @param basePath A root directory to resolve relative path entries in the config
|
||||
* file to. e.g. outDir
|
||||
*/
|
||||
function parseConfigFile(json: any, basePath?: string): ParsedCommandLine;
|
||||
function parseConfigFile(json: any, host: ParseConfigHost, basePath: string): ParsedCommandLine;
|
||||
}
|
||||
declare module ts {
|
||||
/** The version of the language service API */
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user