1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-04-26 15:08:27 -04:00
jarv.is/types/note.d.ts
2023-03-08 18:03:56 -05:00

26 lines
611 B
TypeScript

import type { MDXRemoteSerializeResult } from "next-mdx-remote";
export type NoteFrontMatter = {
slug: string;
permalink: string;
date: string;
title: string;
htmlTitle?: string;
description?: string;
image?: string;
tags?: string[];
noComments?: boolean;
};
export type NoteWithSource = {
// yaml metadata
frontMatter: NoteFrontMatter;
// the final, compiled JSX by next-mdx-remote; see lib/helpers/parse-notes.ts
source: Partial<Pick<MDXRemoteSerializeResult<Record<string, never>, Record<string, never>>>>;
};
export type NotesByYear = {
[year: string]: NoteFrontMatter[];
};