fix: 글자 크기 A-/A/A+ 버튼 동작 수정#438
Merged
Merged
Conversation
prop 전달 대신 uiSettingsStore.changeContentFontSize() 직접 호출
sdk-kr
pushed a commit
that referenced
this pull request
Apr 20, 2026
backend PR #438 + premium PR #37 inline 데이터 활용. 글 상세 페이지의 post.author_memo로 memo-store cache 미리 채워 별도 fetch 회피. 변경: - preloadMemos optional 함수 동적 import 추가 - $effect: preloadMemos([data.post]) — post 작성자 memo cache 등록 - memo-badge mount 시 cache hit → loadMemo() fetch 발생 안 함 호환성: - preloadMemos 없으면 기존 loadMemosForAuthors fallback (PR #1252 패턴) - author_memo 없으면 null 등록 → 메모 없음 표시 정상
4 tasks
sdk-kr
added a commit
that referenced
this pull request
Apr 20, 2026
…1253) ## Summary W4-X 시리즈 마무리. 글 상세 페이지에서 post.author_memo (backend PR #438 inline) 데이터로 memo-store cache 미리 채워 별도 fetch 회피. ## 분석 결과 [boardId]/+page.svelte (게시판 목록), recent-posts.svelte는 **자체 batch fetch 사용** (memo-badge에 prop 직접 전달) — N+1 없음. [boardId]/[postId]/+page.svelte (**글 상세**) 만 memo-store loadMemosForAuthors 사용 → memo-badge mount 시 single fetch. ## 변경 `apps/web/src/routes/[boardId]/[postId]/+page.svelte`: - preloadMemos optional 함수 동적 import 추가 - $effect: `preloadMemos([data.post])` — post 작성자 cache 등록 - memo-badge mount 시 cache hit → fetch 0 ## 호환성 - preloadMemos 없으면 (구 premium) 기존 loadMemosForAuthors fallback - author_memo 없으면 (구 backend) null 등록 → 메모 없음 표시 정상 ## 예상 효과 - 글 상세 페이지 /memo individual 호출 0 - comment-list (PR #1252) + 이번 PR로 W4-X 완결 - 408/5min → ~50/5min (캐시된 구 클라 일부 잔존) ## Test plan - [x] pnpm check 0 errors - [ ] CI pass - [ ] 새벽 4시 prod 배포 - [ ] OTel: /memo individual 추세 감소 확인 Co-authored-by: sdk-kr <deploy@damoang.net>
5 tasks
sdk-kr
added a commit
that referenced
this pull request
Apr 21, 2026
…4) (#1256) ## Summary 게시판 목록 페이지에서 backend inline author_memo (PR #438)로 memo-store memoCache 미리 채우기. memo-badge가 내부에서 loadMemo() 호출해도 cache hit → \`/api/v1/members/{id}/memo\` individual fetch 0. ## 4/21 측정 | 시각 | individual | batch | 비율 | |------|---:|---:|---:| | 11:20 | 1,412 | 1,365 | **1.03** | | 12:30 | 1,120 | 1,097 | 1.02 | **1:1 비율 정체** = 매 batch 호출 시마다 individual 1회 추가 발생. ## 근본 원인 (이중 cache 불일치) \`[boardId]/+page.svelte\`에 2개의 독립된 cache: 1. **page 자체 \`memoByAuthorId\`** (L190) — 자체 batch fetch 2. **memo-store \`memoCache\`** (premium plugin) — memo-badge가 조회 memo-badge가 \`$derived(getMemo(id))\` 호출 → memoCache 조회 → 없음 → \`loadMemo()\` → batch queue → **또 batch 1회**. ## 해결 \`preloadMemos(posts)\` 로 memoCache 직접 채움: - memo-badge \`loadMemo()\` cache hit → fetch 0 - 기존 자체 batch는 inline classic layout 렌더링 용도로 유지 - 후속 PR에서 자체 batch 제거 가능 (W4-X5) ## 변경 \`[boardId]/+page.svelte\`: 1. \`loadPluginLib\` import 추가 2. \`preloadMemos\` state + 동적 import \$effect 3. 목록 데이터 \$effect 내 \`preloadMemos(items)\` 호출 ## 안전성 - preloadMemos 없어도 (구 premium) 회귀 없음 (기존 flow 유지) - idempotent (cache 있으면 skip) - 자체 batch + preloadMemos 중복 무해 (cache hit로 마지막 쿼리 skip) ## Test plan - [x] \`pnpm check\` 0 errors - [ ] CI pass - [ ] 새벽 4시 prod 배포 - [ ] OTel: individual 1,400/10min → **10 이하** (목표) - [ ] 메모 배지 정상 표시 (회귀 0) ## 관련 (W4-X 시리즈) - Phase 1: damoang-backend#438 (author_memo inline) ✅ - Phase 2: damoang-premium#37 (preloadMemos) + #1252 (comment-list) ✅ - Phase 3: #1253 (post-detail) ✅ - **Phase 4 (이 PR)**: board-list — 최종 완결 ## 후속 (W4-X5+, 1주 후) - 자체 \`memoByAuthorId\` local state 제거 - Legacy GET /memo endpoint deprecate (W4-C 패턴) Co-authored-by: sdk-kr <deploy@damoang.net>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan