feat(IN-320): EP-01, 02 페이지 SEO 적용#137
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Review limit reached
More reviews will be available in 23 minutes and 16 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
개요Next.js 라우트 구조를 표준화하여 모든 페이지의 메타데이터를 .tsx 파일에 선언하도록 통합하고, 기존 .ts 재내보내기 구문을 제거했습니다. 또한 홈페이지의 로그인 상태 기반 동작을 개선하고 클라이언트 컴포넌트 책임을 명확히 했습니다. 변경 사항라우트 메타데이터 및 페이지 구조 표준화
홈페이지 인증 동작 및 컴포넌트 책임 개선
예상 검토 시간🎯 2 (Simple) | ⏱️ ~10분 추천 검토자
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 8
🧹 Nitpick comments (2)
src/pages/main/ui/ChannelProfilePage.tsx (1)
1-1: ⚡ Quick win여기도
@/alias import로 맞춰주세요.
src하위 파일이라 상대 경로보다 alias를 쓰는 쪽이 프로젝트 규칙과 맞습니다.💡 제안 수정
-import { ChannelProfileClient } from './ChannelProfileClient' +import { ChannelProfileClient } from '`@/pages/main/ui/ChannelProfileClient`'As per coding guidelines,
src/**/*.{ts,tsx}: Path Alias@/* 사용하여 ./src/*로 import🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/pages/main/ui/ChannelProfilePage.tsx` at line 1, Update the import in ChannelProfilePage.tsx to use the project path-alias instead of a relative path: replace the local './ChannelProfileClient' import with the alias import for the same module (use '`@/pages/main/ui/ChannelProfileClient`') so the ChannelProfileClient import follows the src/* -> `@/`* guideline.src/pages/home/ui/HomePage.tsx (1)
2-2: ⚡ Quick win상대 경로 대신
@/alias를 사용하세요.이 파일은
src하위라서./HomeAuthGuard보다 alias import로 맞추는 편이 현재 규칙과 일관됩니다.💡 제안 수정
-import HomeAuthGuard from './HomeAuthGuard' +import HomeAuthGuard from '`@/pages/home/ui/HomeAuthGuard`'As per coding guidelines,
src/**/*.{ts,tsx}: Path Alias@/* 사용하여 ./src/*로 import🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/pages/home/ui/HomePage.tsx` at line 2, Change the relative import in HomePage.tsx to use the project path alias instead of a local relative path: replace "import HomeAuthGuard from './HomeAuthGuard'" with an alias import that points to the same module (e.g. import HomeAuthGuard from '`@/pages/home/ui/HomeAuthGuard`'), ensuring the symbol HomeAuthGuard is imported via the `@/` alias to conform to the src/**/*.{ts,tsx} import rule.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@app/`(protected)/(channelLinked)/channel/page.tsx:
- Around line 1-26: This file defines metadata and a Page component inline;
convert it to the App Router re-export pattern by removing the local metadata
and Page implementation and instead re-export the page and metadata from the
shared page module (the module that currently exports ChannelPage, e.g.
'`@/pages/channel`' or its index.ts). Specifically, replace the inline exports
with re-exports such as exporting the page default and metadata from the
existing src/pages channel module (ensure you re-export the same symbol names
that module provides, e.g. export { default, metadata } from '`@/pages/channel`'
or equivalent), and delete the local const title/description and the Page
function.
In `@app/`(protected)/(channelLinked)/videos/[videoId]/page.tsx:
- Around line 1-12: Replace the inline page component with a re-export so the
dynamic route follows the app/*/page.ts re-export convention: instead of
defining export const metadata and default function Page that returns
VideoDetailPage, re-export the page module and its metadata from the centralized
page module (the module currently imported as '`@/pages/videoDetail`' which
exports VideoDetailPage and its metadata). Concretely, remove the local metadata
and Page implementation and export the default and metadata from the existing
src/pages videoDetail module so routing and metadata are managed from that
single source of truth.
In `@app/`(protected)/(channelLinked)/videos/page.tsx:
- Around line 1-12: The file currently defines and returns the VideosPage
component directly (imported as VideosPage and exported via default function
Page), but per routing rules it should be a re-export entry; remove the local
Page component and the VideosPage import and instead re-export the page module
from the canonical pages entry (e.g. export { default } from '`@/pages/videos`' or
export * from '`@/pages/videos`'), so Page becomes a simple re-export that
forwards the implementation in src/pages/videos/index.ts (or the module
referenced as '`@/pages/videos`').
In `@app/`(protected)/main/page.tsx:
- Around line 1-26: Replace the direct component and metadata definitions in
this file with a re-export per the routing rule: remove the local metadata, Page
component and the ChannelProfilePage import and instead re-export the page
module and its metadata from the canonical page module (the module currently
referenced as '`@/pages/main`' which exports metadata and the default component).
In other words, export the default and metadata from the src/pages main entry
(so consumers get exported metadata and the default Page via a single
re-export).
In `@app/`(public)/page.tsx:
- Around line 1-26: Replace the current in-file definitions with a re-export
from the page module: remove the local metadata, title/description constants,
and the Page component that returns HomePage, and instead re-export the default
page and metadata from the home page module (the module that currently defines
HomePage and its metadata, e.g. the src/pages/home index that exports metadata
and the default component). Ensure you re-export the same symbols (metadata and
the default export) so the app/(public)/page.tsx becomes a simple re-export of
the home page module rather than defining metadata or HomePage locally.
In `@src/pages/home/ui/HomeAuthGuard.tsx`:
- Around line 25-34: The effect in useEffect currently runs even for logged-in
users causing global snap classes to be added; update the guard to also skip
when the user is authenticated (e.g., add an auth flag such as isAuthenticated
or sessionUser to the dependency list) by changing the early-return to if
(isInitializing || isAuthenticated) return; so the
document.documentElement.classList.add('snap-landing') and
footer?.classList.add('snap-start') only run for unauthenticated users and
ensure the cleanup still removes classes when the effect was applied; reference
useEffect, isInitializing, isAuthenticated (or sessionUser),
document.documentElement.classList, and footer?.classList.
In `@src/pages/main/ui/ChannelProfileClient.tsx`:
- Line 16: The container div rendering in ChannelProfileClient uses a typo in
the className string ("felx h-fit w-full flex-col px-24 pt-40 pb-96") so the
flex layout isn't applied; update the className on that div to replace "felx"
with "flex" (ensure the JSX element that currently contains className='felx
h-fit w-full flex-col px-24 pt-40 pb-96' is changed to use "flex") to restore
the intended flex behavior.
- Around line 9-18: Remove the unsafe type assertion on channelId (do not use
"as string"); instead read it via useAuth
(user?.userChannelDetails?.youtubeChannelId) and guard rendering: if channelId
is undefined show a loading/fallback or return null before rendering
ChannelProfileSection, TrendingVideosSection, and TrendMagazineSection, or pass
channelId only when defined to those components (identify ChannelProfileSection,
TrendingVideosSection, TrendMagazineSection and the
useAuth/user.userChannelDetails access point to implement the conditional render
or fallback).
---
Nitpick comments:
In `@src/pages/home/ui/HomePage.tsx`:
- Line 2: Change the relative import in HomePage.tsx to use the project path
alias instead of a local relative path: replace "import HomeAuthGuard from
'./HomeAuthGuard'" with an alias import that points to the same module (e.g.
import HomeAuthGuard from '`@/pages/home/ui/HomeAuthGuard`'), ensuring the symbol
HomeAuthGuard is imported via the `@/` alias to conform to the src/**/*.{ts,tsx}
import rule.
In `@src/pages/main/ui/ChannelProfilePage.tsx`:
- Line 1: Update the import in ChannelProfilePage.tsx to use the project
path-alias instead of a relative path: replace the local
'./ChannelProfileClient' import with the alias import for the same module (use
'`@/pages/main/ui/ChannelProfileClient`') so the ChannelProfileClient import
follows the src/* -> `@/`* guideline.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 4b69e339-34fa-4165-a7e1-cbdd8db3c335
⛔ Files ignored due to path filters (7)
public/og-channel-analyze.pngis excluded by!**/*.pngpublic/og-channel-score.pngis excluded by!**/*.pngpublic/og-competitor.pngis excluded by!**/*.pngpublic/og-influencer.pngis excluded by!**/*.pngpublic/og-main.pngis excluded by!**/*.pngpublic/og-me.pngis excluded by!**/*.pngsrc/shared/assets/mock/mock-image.pngis excluded by!**/*.png
📒 Files selected for processing (16)
app/(protected)/(channelLinked)/channel/page.tsapp/(protected)/(channelLinked)/channel/page.tsxapp/(protected)/(channelLinked)/videos/[videoId]/page.tsapp/(protected)/(channelLinked)/videos/[videoId]/page.tsxapp/(protected)/(channelLinked)/videos/layout.tsxapp/(protected)/(channelLinked)/videos/page.tsapp/(protected)/(channelLinked)/videos/page.tsxapp/(protected)/main/page.tsapp/(protected)/main/page.tsxapp/(public)/page.tsapp/(public)/page.tsxsrc/entities/home/featureCard/FeatureCard.tsxsrc/pages/home/ui/HomeAuthGuard.tsxsrc/pages/home/ui/HomePage.tsxsrc/pages/main/ui/ChannelProfileClient.tsxsrc/pages/main/ui/ChannelProfilePage.tsx
💤 Files with no reviewable changes (5)
- app/(protected)/(channelLinked)/videos/page.ts
- app/(protected)/(channelLinked)/videos/[videoId]/page.ts
- app/(protected)/(channelLinked)/channel/page.ts
- app/(protected)/main/page.ts
- app/(public)/page.ts
SEO 적용은 app 폴더 안에서만 진행되므로 src/pages안의 페이지들은 use client 상태를 유지해도 상관이 없기에 파일을 복원함
타입 단언을 channelId가 undefined인 경우도 처리가능하도록 수정
📌 작업 개요
홈페이지 SEO 적용
로그인 후 랜딩 페이지 SEO 적용
채널 분석 페이지 SEO 적용
영상 성과 분석 페이지 SEO 적용
🗂 작업 유형
✏️ 작업 내용
✅ 셀프 체크리스트
💬 리뷰어에게
Summary by CodeRabbit
릴리스 노트
새로운 기능
버그 수정
리팩토링