Skip to content

Commit 58c8d34

Browse files
committed
Update LKG
1 parent f5a52ee commit 58c8d34

File tree

11 files changed

+1726
-821
lines changed

11 files changed

+1726
-821
lines changed

lib/lib.d.ts

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -965,38 +965,22 @@ interface JSON {
965965
* If a member contains nested objects, the nested objects are transformed before the parent object is.
966966
*/
967967
parse(text: string, reviver?: (key: any, value: any) => any): any;
968-
/**
969-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
970-
* @param value A JavaScript value, usually an object or array, to be converted.
971-
*/
972-
stringify(value: any): string;
973-
/**
974-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
975-
* @param value A JavaScript value, usually an object or array, to be converted.
976-
* @param replacer A function that transforms the results.
977-
*/
978-
stringify(value: any, replacer: (key: string, value: any) => any): string;
979-
/**
980-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
981-
* @param value A JavaScript value, usually an object or array, to be converted.
982-
* @param replacer Array that transforms the results.
983-
*/
984-
stringify(value: any, replacer: any[]): string;
985968
/**
986969
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
987970
* @param value A JavaScript value, usually an object or array, to be converted.
988971
* @param replacer A function that transforms the results.
989972
* @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.
990973
*/
991-
stringify(value: any, replacer: (key: string, value: any) => any, space: string | number): string;
974+
stringify(value: any, replacer?: (key: string, value: any) => any, space?: string | number): string;
992975
/**
993976
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
994977
* @param value A JavaScript value, usually an object or array, to be converted.
995-
* @param replacer Array that transforms the results.
978+
* @param replacer An array of strings and numbers that acts as a white list for selecting the object properties that will be stringified.
996979
* @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.
997980
*/
998-
stringify(value: any, replacer: any[], space: string | number): string;
981+
stringify(value: any, replacer?: (number | string)[] | null, space?: string | number): string;
999982
}
983+
1000984
/**
1001985
* An intrinsic object that provides functions to convert JavaScript values to and from the JavaScript Object Notation (JSON) format.
1002986
*/

lib/lib.es5.d.ts

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -965,38 +965,22 @@ interface JSON {
965965
* If a member contains nested objects, the nested objects are transformed before the parent object is.
966966
*/
967967
parse(text: string, reviver?: (key: any, value: any) => any): any;
968-
/**
969-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
970-
* @param value A JavaScript value, usually an object or array, to be converted.
971-
*/
972-
stringify(value: any): string;
973-
/**
974-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
975-
* @param value A JavaScript value, usually an object or array, to be converted.
976-
* @param replacer A function that transforms the results.
977-
*/
978-
stringify(value: any, replacer: (key: string, value: any) => any): string;
979-
/**
980-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
981-
* @param value A JavaScript value, usually an object or array, to be converted.
982-
* @param replacer Array that transforms the results.
983-
*/
984-
stringify(value: any, replacer: any[]): string;
985968
/**
986969
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
987970
* @param value A JavaScript value, usually an object or array, to be converted.
988971
* @param replacer A function that transforms the results.
989972
* @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.
990973
*/
991-
stringify(value: any, replacer: (key: string, value: any) => any, space: string | number): string;
974+
stringify(value: any, replacer?: (key: string, value: any) => any, space?: string | number): string;
992975
/**
993976
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
994977
* @param value A JavaScript value, usually an object or array, to be converted.
995-
* @param replacer Array that transforms the results.
978+
* @param replacer An array of strings and numbers that acts as a white list for selecting the object properties that will be stringified.
996979
* @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.
997980
*/
998-
stringify(value: any, replacer: any[], space: string | number): string;
981+
stringify(value: any, replacer?: (number | string)[] | null, space?: string | number): string;
999982
}
983+
1000984
/**
1001985
* An intrinsic object that provides functions to convert JavaScript values to and from the JavaScript Object Notation (JSON) format.
1002986
*/

lib/lib.es6.d.ts

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -965,38 +965,22 @@ interface JSON {
965965
* If a member contains nested objects, the nested objects are transformed before the parent object is.
966966
*/
967967
parse(text: string, reviver?: (key: any, value: any) => any): any;
968-
/**
969-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
970-
* @param value A JavaScript value, usually an object or array, to be converted.
971-
*/
972-
stringify(value: any): string;
973-
/**
974-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
975-
* @param value A JavaScript value, usually an object or array, to be converted.
976-
* @param replacer A function that transforms the results.
977-
*/
978-
stringify(value: any, replacer: (key: string, value: any) => any): string;
979-
/**
980-
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
981-
* @param value A JavaScript value, usually an object or array, to be converted.
982-
* @param replacer Array that transforms the results.
983-
*/
984-
stringify(value: any, replacer: any[]): string;
985968
/**
986969
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
987970
* @param value A JavaScript value, usually an object or array, to be converted.
988971
* @param replacer A function that transforms the results.
989972
* @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.
990973
*/
991-
stringify(value: any, replacer: (key: string, value: any) => any, space: string | number): string;
974+
stringify(value: any, replacer?: (key: string, value: any) => any, space?: string | number): string;
992975
/**
993976
* Converts a JavaScript value to a JavaScript Object Notation (JSON) string.
994977
* @param value A JavaScript value, usually an object or array, to be converted.
995-
* @param replacer Array that transforms the results.
978+
* @param replacer An array of strings and numbers that acts as a white list for selecting the object properties that will be stringified.
996979
* @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.
997980
*/
998-
stringify(value: any, replacer: any[], space: string | number): string;
981+
stringify(value: any, replacer?: (number | string)[] | null, space?: string | number): string;
999982
}
983+
1000984
/**
1001985
* An intrinsic object that provides functions to convert JavaScript values to and from the JavaScript Object Notation (JSON) format.
1002986
*/

0 commit comments

Comments
 (0)