mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2025-07-03 15:16:40 -04:00
prepare for new next/link
behavior
see new-next-link branch
This commit is contained in:
@ -25,7 +25,7 @@ export const getStaticProps: GetStaticProps = async () => {
|
||||
const notes = await getAllNotes();
|
||||
const notesByYear: NotesListProps["notesByYear"] = {};
|
||||
|
||||
notes.map((note) => {
|
||||
notes.forEach((note) => {
|
||||
const year = new Date(note.date).getUTCFullYear();
|
||||
(notesByYear[year] || (notesByYear[year] = [])).push(note);
|
||||
});
|
||||
|
Reference in New Issue
Block a user