feat!: add pagefind for static search (#458)

Replace React with pagefind for static site search
This commit is contained in:
Sat Naing
2025-03-07 08:53:16 +07:00
parent 79c7df45e5
commit 9119125643
6 changed files with 191 additions and 4 deletions
+2 -1
View File
@@ -74,6 +74,7 @@ const nextPost =
"mx-auto w-full max-w-3xl px-4 pb-12",
{ "mt-8": !SITE.showBackButton },
]}
data-pagefind-body
>
<h1
transition:name={slugifyStr(title)}
@@ -119,7 +120,7 @@ const nextPost =
<hr class="my-6 border-dashed" />
<!-- Previous/Next Post Buttons -->
<div class="grid grid-cols-1 gap-6 sm:grid-cols-2">
<div data-pagefind-ignore class="grid grid-cols-1 gap-6 sm:grid-cols-2">
{
prevPost && (
<a