Add Pagefind search, sort posts by update time, link DigiKedai bot repo
Deploy / build (push) Successful in 20s
Deploy / build (push) Successful in 20s
This commit is contained in:
1 parent
dfd9612a6b
commit
93c716f876
12 files changed
+369
-13
No files matched your search
@@ -4,9 +4,9 @@ import PostList from '../components/PostList.astro';
|
||||
import { getCollection } from 'astro:content';
|
||||
import { isEn } from '../lib/lang';
|
||||
import { SITE } from '../config';
|
||||
import { sortByUpdated } from '../lib/sort';
|
||||
|
||||
const posts = (await getCollection('posts', isEn))
|
||||
.sort((a, b) => b.data.pubDate.valueOf() - a.data.pubDate.valueOf());
|
||||
const posts = sortByUpdated(await getCollection('posts', isEn));
|
||||
---
|
||||
|
||||
<BaseLayout title={SITE.title} description={SITE.description}>
|
||||
|
||||
Reference in new issue
Block a user