10 lines
245 B
TypeScript
10 lines
245 B
TypeScript
import { calendar } from '@/hooks/calendars'
|
|
|
|
/**
|
|
* Return liturgical name of the date
|
|
* e.G. "2024-12-25" => Christmas
|
|
*/
|
|
export const liturgicalDayName = (date: string) => {
|
|
const day = calendar[date.substring(0, 10)]
|
|
return day.name
|
|
}
|