Skip to content

Add post on Pagefind search integration for static export - #99

Merged
CoBool merged 1 commit into
mainfrom
claude/posts-review-recommendation-ch9n4t
Aug 22, 2026
Merged

Add post on Pagefind search integration for static export#99
CoBool merged 1 commit into
mainfrom
claude/posts-review-recommendation-ch9n4t

Conversation

@CoBool

@CoBool CoBool commented Aug 22, 2026

Copy link
Copy Markdown
Owner

변경 내용

content/posts/pagefind-search-without-a-server.md 신규 포스트 추가. output: "export" 정적 블로그에 Pagefind로 검색을 붙인 과정을 다룬다.

변경 이유

기존 포스트 3편을 검토한 뒤, 코드베이스에 이미 구현돼 있지만 아직 글로 다루지 않은 주제로 검색 기능(src/features/search)을 추천받아 작성했다. 다루는 내용:

  • 직접 인덱서를 만드는 대신 postbuild에서 pagefind --site out을 돌리기로 한 이유
  • 빌드 이후에만 존재하는 번들을 webpackIgnore/turbopackIgnore로 동적 import하는 방식
  • 번들 로드용 모듈 캐시와, 실패 시 캐시를 리셋해 재시도를 허용하는 처리
  • dangerouslySetInnerHTML 대신 Pagefind 발췌의 <mark> 태그를 직접 파싱하고 HTML 엔티티를 디코딩하는 방식

검증

  • 신규 Markdown 파일 추가만 있는 변경으로, 코드 수정은 없음
  • frontmatter를 CONTENT.md의 필수 필드 규칙(title, date, category, tags)에 맞춰 작성

Generated by Claude Code

Covers why an existing indexer was chosen over a hand-rolled index,
the postbuild-only bundle load, module-cache failure recovery, and
manually parsing <mark> excerpts instead of dangerouslySetInnerHTML.
@CoBool
CoBool merged commit cd41add into main Aug 22, 2026
1 check passed
@CoBool
CoBool deleted the claude/posts-review-recommendation-ch9n4t branch August 22, 2026 06:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants