Merge pull request #33502 from adamzerella/types/repeat-string

[repeat-string] Add typing for repeat-string
This commit is contained in:
Nathan Shively-Sanders
2019-03-07 16:07:01 -08:00
committed by GitHub
4 changed files with 42 additions and 0 deletions
+11
View File
@@ -0,0 +1,11 @@
// Type definitions for repeat-string 1.6
// Project: https://github.com/jonschlinkert/repeat-string
// Definitions by: Adam Zerella <https://github.com/adamzerella>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
/**
* Repeat the given `string` the specified `number` of times.
*/
declare function repeat(str: string, num: number): string;
export = repeat;
@@ -0,0 +1,3 @@
import Repeat = require("repeat-string");
Repeat('A', 5);
+25
View File
@@ -0,0 +1,25 @@
{
"compilerOptions": {
"module": "commonjs",
"lib": [
"es6"
],
"noImplicitAny": true,
"noImplicitThis": true,
"strictNullChecks": true,
"strictFunctionTypes": true,
"baseUrl": "../",
"typeRoots": [
"../"
],
"types": [
],
"noEmit": true,
"forceConsistentCasingInFileNames": true
},
"files": [
"index.d.ts",
"repeat-string-tests.ts"
]
}
+3
View File
@@ -0,0 +1,3 @@
{
"extends": "dtslint/dt.json"
}