diff options
| author | Danilo M. <danix@danix.xyz> | 2026-04-20 13:59:05 +0200 |
|---|---|---|
| committer | Danilo M. <danix@danix.xyz> | 2026-04-20 13:59:05 +0200 |
| commit | 60f1a9352ed91135b531e14e7d061c0a1987cd0b (patch) | |
| tree | 2c21fa2ac64481523392e00d6b8f12981396c9c8 /themes/danix-xyz-hacker/layouts/404.en.html | |
| parent | 7ac53237b95c798beb57b37f2f7bf38be1f4056b (diff) | |
| download | danixxyz-60f1a9352ed91135b531e14e7d061c0a1987cd0b.tar.gz danixxyz-60f1a9352ed91135b531e14e7d061c0a1987cd0b.zip | |
refactor: unify 404 page with shared search functionality
Removes inline window.articlesData from both 404 pages. not-found-page.js now uses shared notFoundPage Alpine component from search.js (lazy-loaded index). Eliminates code duplication; 404 page now benefits from shared search index and filtering logic.
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Diffstat (limited to 'themes/danix-xyz-hacker/layouts/404.en.html')
| -rw-r--r-- | themes/danix-xyz-hacker/layouts/404.en.html | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/themes/danix-xyz-hacker/layouts/404.en.html b/themes/danix-xyz-hacker/layouts/404.en.html index 6ed4892..8d8641d 100644 --- a/themes/danix-xyz-hacker/layouts/404.en.html +++ b/themes/danix-xyz-hacker/layouts/404.en.html @@ -1,19 +1,5 @@ {{ define "main" }} -<!-- Pass articles data to JavaScript for Alpine.js --> -<script> -window.articlesData = [ - {{ range (where .Site.RegularPages "Section" "articles") }} - { - title: '{{ .Title | safeJS }}', - url: '{{ .Permalink }}', - date: '{{ .Date.Format "Jan 02, 2006" }}', - content: '{{ (.Summary | plainify | safeJS) }}' - }, - {{ end }} -]; -</script> - <main class="min-h-screen px-4 py-12"> <div class="mx-auto px-4 py-12 max-w-4xl border border-border glow-accent rounded-lg bg-bg p-8" x-data="notFoundPage()"> <div class="text-center"> |
