1 | export as namespace Classcat
|
2 |
|
3 | export interface ClassObject {
|
4 | [key: string]: boolean | any
|
5 | }
|
6 |
|
7 | export interface ClassArray extends Array<Class> {}
|
8 |
|
9 | export type Class = string | number | ClassObject | ClassArray
|
10 |
|
11 | /**
|
12 | * Classcat is a unary function expecting an array of elements _or_ an object of key/value pairs and returns a string that is the result of joining all the elements in the array or object keys.
|
13 | *
|
14 | * [Falsy](https://developer.mozilla.org/en-US/docs/Glossary/Falsy) array elements and object properties will be ignored.
|
15 | *
|
16 | * @param classNames
|
17 | */
|
18 | export default function(classNames: Class): string
|
19 |
|
\ | No newline at end of file |