Correct typings for runes (#34841)

* Update runes-tests.ts

* Update runes types

Correct to account for width param
This commit is contained in:
Aaron Osher
2019-04-19 12:53:09 -07:00
committed by Armando Aguirre
parent ba3d094519
commit c198645a5b
2 changed files with 2 additions and 1 deletions
+1 -1
View File
@@ -5,7 +5,7 @@
declare function runes(text: string): string[];
declare namespace runes {
function substr(text: string, index: number): string;
function substr(text: string, start: number, width?: number): string;
}
export = runes;
+1
View File
@@ -2,3 +2,4 @@ import runes = require('runes');
runes('hello world 😁');
runes.substr('hello world 😁', 1);
runes.substr('hello world 😁', 1, 5);