mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-04 12:32:08 -06:00
* add types for escape and unescape methods #18813 although the issue is marked working as expected, it is important to mention that most major browsers maintain support for escape and unescape, and some javascript codebases moving to typescript may have escape and unescape in them. They are valid JavaScript, and thus they should be included in the global definition. * add escape and unescape types to lib in tests * update tests to turn CI green
This commit is contained in:
parent
e7df83263d
commit
c2f0c580db
12
src/lib/es5.d.ts
vendored
12
src/lib/es5.d.ts
vendored
@ -62,6 +62,18 @@ declare function encodeURI(uri: string): string;
|
||||
*/
|
||||
declare function encodeURIComponent(uriComponent: string): string;
|
||||
|
||||
/**
|
||||
* Computes a new string in which certain characters have been replaced by a hexadecimal escape sequence.
|
||||
* @param string A string value
|
||||
*/
|
||||
declare function escape(string: string): string;
|
||||
|
||||
/**
|
||||
* Computes a new string in which hexadecimal escape sequences are replaced with the character that it represents.
|
||||
* @param string A string value
|
||||
*/
|
||||
declare function unescape(string: string): string;
|
||||
|
||||
interface PropertyDescriptor {
|
||||
configurable?: boolean;
|
||||
enumerable?: boolean;
|
||||
|
||||
@ -6,5 +6,5 @@
|
||||
////var f = function () { return new/**/; }
|
||||
|
||||
goTo.marker();
|
||||
verify.completionListCount(115);
|
||||
verify.completionListCount(117);
|
||||
verify.completionListContains('new');
|
||||
|
||||
@ -5,6 +5,6 @@
|
||||
////var f = function (s) { return this/**/; }
|
||||
|
||||
goTo.marker();
|
||||
verify.completionListCount(116);
|
||||
verify.completionListCount(118);
|
||||
verify.completionListContains('this');
|
||||
|
||||
|
||||
@ -4,4 +4,4 @@
|
||||
//// var x = </**/;
|
||||
|
||||
goTo.marker();
|
||||
verify.completionListCount(42);
|
||||
verify.completionListCount(44);
|
||||
|
||||
1652
tests/lib/lib.d.ts
vendored
1652
tests/lib/lib.d.ts
vendored
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user