mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
feat(types): Add typings for "arr-union" package
This commit is contained in:
parent
1a051f0000
commit
cd481a908a
7
types/arr-union/arr-union-tests.ts
Normal file
7
types/arr-union/arr-union-tests.ts
Normal file
@ -0,0 +1,7 @@
|
||||
import union = require('arr-union');
|
||||
|
||||
// $ExpectType string[]
|
||||
union(['a'], ['b', 'c'], ['d', 'e', 'f']);
|
||||
|
||||
// $ExpectType number[]
|
||||
union([1, 1], [2, 3]);
|
||||
8
types/arr-union/index.d.ts
vendored
Normal file
8
types/arr-union/index.d.ts
vendored
Normal file
@ -0,0 +1,8 @@
|
||||
// Type definitions for arr-union 3.1
|
||||
// Project: https://github.com/jonschlinkert/arr-union
|
||||
// Definitions by: mrmlnc <https://github.com/mrmlnc>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
declare function union<T>(...arrays: Array<ArrayLike<T>>): T[];
|
||||
|
||||
export = union;
|
||||
23
types/arr-union/tsconfig.json
Normal file
23
types/arr-union/tsconfig.json
Normal 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",
|
||||
"arr-union-tests.ts"
|
||||
]
|
||||
}
|
||||
1
types/arr-union/tslint.json
Normal file
1
types/arr-union/tslint.json
Normal file
@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Loading…
Reference in New Issue
Block a user