(eventA: Event, eventB: Event)
| 6 | import { getAllContributors } from "./contributors"; |
| 7 | |
| 8 | function sortByEventStartDate(eventA: Event, eventB: Event) { |
| 9 | const date1 = dayjs(eventA.startDate.date); |
| 10 | const date2 = dayjs(eventB.startDate.date); |
| 11 | if (date1.isBefore(date2)) return 1; |
| 12 | if (date1.isAfter(date2)) return -1; |
| 13 | return 0; |
| 14 | } |
| 15 | |
| 16 | export async function getAllEvents(withContent?: boolean) { |
| 17 | const directory = "data/events"; |
nothing calls this directly
no outgoing calls
no test coverage detected