Fix sorting
This commit is contained in:
parent
4566c85c44
commit
af1cd7ed91
1 changed files with 2 additions and 2 deletions
|
@ -7,10 +7,10 @@ import { getCollection } from 'astro:content';
|
|||
import FormattedDate from '../../components/FormattedDate.astro';
|
||||
|
||||
const posts = (await getCollection('blog')).sort(
|
||||
(a, b) => a.data.pubDate.valueOf() - b.data.pubDate.valueOf()
|
||||
(b, a) => a.data.pubDate.valueOf() - b.data.pubDate.valueOf()
|
||||
);
|
||||
const homelab_posts = (await getCollection('homelab')).sort(
|
||||
(a, b) => a.data.pubDate.valueOf() - b.data.pubDate.valueOf()
|
||||
(b, a) => a.data.pubDate.valueOf() - b.data.pubDate.valueOf()
|
||||
);
|
||||
---
|
||||
|
||||
|
|
Loading…
Reference in a new issue