personal-website/lib/notion/utils/sorts.ts
Filipe Medeiros 9a9638237f
feat: initial commit
Signed-off-by: Filipe Medeiros <hello@filipesm.eu>
2023-12-03 12:25:52 +01:00

10 lines
277 B
TypeScript

export const sortProperty = (
property: string,
direction: 'ascending' | 'descending'
) => ({ property, direction });
export const sortTimestamp = (
timestamp: 'last_edited_time' | 'created_time',
direction: 'ascending' | 'descending'
) => ({ timestamp, direction });