diff --git a/src/index.ts b/src/index.ts index 7e06e3b..0da6765 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,8 +1,9 @@ export * from './domain/UniDateTime'; export * from './domain/UniDuration'; export * from './logic/utils/sleep'; -export * from './logic/checks/isUniDate'; export * from './logic/checks/isUniDateTime'; +export * from './logic/checks/isUniDate'; +export * from './logic/checks/isUniMonth'; export * from './logic/casts/toMillisecondsSinceEpoch'; export * from './logic/manipulate/addDuration'; export * from './logic/manipulate/getDuration'; diff --git a/src/logic/checks/isUniMonth.ts b/src/logic/checks/isUniMonth.ts index 92cc69f..14ffbd9 100644 --- a/src/logic/checks/isUniMonth.ts +++ b/src/logic/checks/isUniMonth.ts @@ -1,7 +1,7 @@ import { format, parseISO } from 'date-fns'; import { withAssure } from 'type-fns'; -import { UniDate } from '../../domain/UniDateTime'; +import { UniMonth } from '../../domain/UniDateTime'; import { castInputToDate } from '../casts/castInputToDate'; /** @@ -9,12 +9,12 @@ import { castInputToDate } from '../casts/castInputToDate'; */ export const asUniMonth = ( input: Parameters[0], -): UniDate => format(castInputToDate(input), 'yyyy-MM') as UniDate; +): UniMonth => format(castInputToDate(input), 'yyyy-MM') as UniMonth; /** * checks whether a string literal input is a UniDate */ -export const isUniMonth = withAssure((input: string): input is UniDate => { +export const isUniMonth = withAssure((input: string): input is UniMonth => { try { return asUniMonth(parseISO(input)) === input; } catch {