Add String#lastIndexOf and improve tests (#163)

This commit is contained in:
Max Graey
2018-07-10 04:31:51 +03:00
committed by Daniel Wirtz
parent c4199673ef
commit 365884ff73
11 changed files with 2112 additions and 1172 deletions

View File

@ -280,14 +280,14 @@ declare class String {
private constructor();
indexOf(subject: string, position?: i32): i32;
indexOf(other: string, fromIndex?: i32): i32;
lastIndexOf(other: string, fromIndex?: i32): i32;
includes(other: string): bool;
lastIndexOf(subject: string, position?: i32): i32;
charAt(index: i32): string;
charCodeAt(index: i32): i32;
substring(from: i32, to?: i32): string;
startsWith(subject: string): bool;
endsWith(subject: string): bool;
startsWith(other: string): bool;
endsWith(other: string): bool;
replace(search: string, replacement: string): string;
repeat(count?: i32): string;
toString(): string;