Skip to content

Commit

Permalink
fix: get rid of types.ts file
Browse files Browse the repository at this point in the history
  • Loading branch information
xobotyi committed Jul 10, 2021
1 parent fdec8d1 commit 37071e7
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 17 deletions.
14 changes: 13 additions & 1 deletion src/cnb.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,16 @@
import { ClassListArray } from './types';
export type ClassValue =
| string
| null
| boolean
| undefined
| IClassListDictionary
| ClassListArray;

export type ClassListArray = ClassValue[];

export interface IClassListDictionary {
[cn: string]: any; // it can be anything
}

const { isArray } = Array;

Expand Down
2 changes: 1 addition & 1 deletion src/dcnb.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ClassListArray, ClassValue } from './types';
import type { ClassListArray, ClassValue } from './cnb';

const SPACE_REGEX = /\s+/;
const { create } = Object;
Expand Down
3 changes: 1 addition & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
export { cnb } from './cnb';
export { cnb, ClassValue } from './cnb';
export { dcnb } from './dcnb';
export { ClassValue } from './types';
13 changes: 0 additions & 13 deletions src/types.ts

This file was deleted.

0 comments on commit 37071e7

Please sign in to comment.