Merge pull request #26731 from claasahl/master

new package: "starwars-names"
This commit is contained in:
Nathan Shively-Sanders
2018-06-21 11:30:01 -07:00
committed by GitHub
4 changed files with 38 additions and 0 deletions

9
types/starwars-names/index.d.ts vendored Normal file
View File

@@ -0,0 +1,9 @@
// Type definitions for starwars-names 1.6
// Project: https://github.com/kentcdodds/starwars-names#readme
// Definitions by: Claas Ahlrichs <https://github.com/claasahl>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
export as namespace starwarsNames;
export const all: string[];
export function random(): string;
export function random(number: number): string[];

View File

@@ -0,0 +1,5 @@
import * as names from "starwars-names";
const allNames = names.all;
const randomName = names.random();
const threeRandomNames = names.random(3);

View File

@@ -0,0 +1,23 @@
{
"compilerOptions": {
"module": "commonjs",
"lib": [
"es6"
],
"noImplicitAny": true,
"noImplicitThis": true,
"strictNullChecks": true,
"strictFunctionTypes": true,
"baseUrl": "../",
"typeRoots": [
"../"
],
"types": [],
"noEmit": true,
"forceConsistentCasingInFileNames": true
},
"files": [
"index.d.ts",
"starwars-names-tests.ts"
]
}

View File

@@ -0,0 +1 @@
{ "extends": "dtslint/dt.json" }