Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
WalkthroughFinalCTASection의 기본 버튼 onClick 대상 URL이 https://pinback.today 에서 https://pinback.today/onboarding 으로 변경되었습니다. 다른 구조나 export는 변경되지 않았습니다. Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
Pre-merge checks and finishing touches❌ Failed checks (3 warnings)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests
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 |
|
✅ Storybook chromatic 배포 확인: |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (2)
apps/landing/src/components/FinalCTASection.tsx (2)
22-29: 내비게이션은 링크로 처리하는 게 더 적합 (a11y/성능)SPA 환경이라면 window.location으로 전체 리로드하지 말고 링크 사용을 권장합니다. 디자인시스템 Button이 asChild를 지원한다면 아래처럼 교체해 주세요.
- <Button - variant="primary" - onClick={() => { - window.location.href = 'https://pinback.today/onboarding'; - }} - > - 지금 시작하기 - </Button> + <Button variant="primary" asChild> + <a href="/onboarding">지금 시작하기</a> + </Button>Next.js 환경이라면 Link를 써도 됩니다:
- <Button variant="primary" asChild> - <a href="/onboarding">지금 시작하기</a> - </Button> + <Button variant="primary" asChild> + <Link href="/onboarding">지금 시작하기</Link> + </Button>
25-25: 절대 URL 하드코딩 지양배포/스테이징 도메인 분리 시 유지보수 비용이 커집니다. 동일 도메인 이동이면 상대경로로 충분합니다.
- window.location.href = 'https://pinback.today/onboarding'; + window.location.href = '/onboarding';별도 도메인이 필요하다면 런타임 ENV(예: NEXT_PUBLIC_APP_ORIGIN/VITE_PUBLIC_APP_ORIGIN)로 관리하는 것을 권장합니다.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
apps/landing/src/components/FinalCTASection.tsx(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: storybook
🔇 Additional comments (1)
apps/landing/src/components/FinalCTASection.tsx (1)
25-25: 변경 자체는 OK요구사항대로 온보딩 URL로의 이동 동작은 문제 없어 보입니다.
| variant="primary" | ||
| onClick={() => { | ||
| window.location.href = 'https://pinback.today'; | ||
| window.location.href = 'https://pinback.today/onboarding'; |
There was a problem hiding this comment.
🛠️ Refactor suggestion
🧩 Analysis chain
URL 변경 영향도 점검 요청
온보딩 경로 접근 조건(로그인/리다이렉션), 분석 이벤트 트래킹, 다른 하드코딩 URL 유무를 확인 부탁드립니다.
🏁 Script executed:
#!/bin/bash
set -euo pipefail
# 1) 레포 내 하드코딩된 prod 도메인 사용처
rg -nP --no-ignore-vcs 'https?://pinback\.today' -C2
# 2) 온보딩 관련 경로 전반 사용처
rg -nP --no-ignore-vcs '\bonboarding\b' -C2
# 3) window.location 직접 사용 패턴 점검 (리로드 유발)
rg -nP --type=ts --type=tsx -C2 '\bwindow\.location\.(href|assign|replace)\b'
# 4) Button의 asChild 사용 사례 유무(디자인시스템 지원 여부 가늠)
rg -nP --type=ts --type=tsx -C2 '\<Button\b[^>]*\basChild\b'Length of output: 5455
하드코딩된 프로덕션 도메인·온보딩 경로 영향 검토 — 수정 필요
레포에서 절대 도메인(https://pinback.today / https://www.pinback.today)과 온보딩 경로 사용처가 확인되었습니다. 도메인 변경 시 동작 불일치 및 확장(extension) 동작 중단 가능.
- apps/landing/src/components/FinalCTASection.tsx:25 — window.location.href = 'https://pinback.today/onboarding';
- apps/extension/src/pages/MainPop.tsx:238 — Icon onClick -> 'https://pinback.today'
- apps/extension/src/App.tsx:27 — window.location.href = "https://pinback.today/";
- apps/extension/src/background.ts:10 — chrome.tabs.create url
https://www.pinback.today/onboarding?email=${info.email}(www 포함) - apps/client/src/shared/apis/setting/axiosInstance.ts:83,89 — window.location.href = '/onboarding' (토큰 관련 리다이렉트)
- apps/client/src/layout/Layout.tsx:6 — location.pathname.startsWith('/onboarding')
- onboarding 관련 컴포넌트 다수(예: apps/client/src/pages/onBoarding/.../StoryStep.tsx)
조치 체크리스트:
- 도메인(www 포함 여부) 하드코딩을 환경변수/상수로 추출.
- extension 코드의 절대 URL 우선 수정(배포 전 반영 필수).
- window.location 직접 사용으로 인한 전체 리로드/상태 손실 여부 확인 → 가능하면 내부 라우터로 대체.
- 토큰 만료 시 리다이렉트(axiosInstance)와 온보딩 접근권한(비로그인 허용 여부) 재검증.
- 온보딩 관련 분석/이벤트 트래킹 위치(analytics 호출) 확인.
🤖 Prompt for AI Agents
In apps/landing/src/components/FinalCTASection.tsx around line 25, the code
hardcodes the production onboarding URL (window.location.href =
'https://pinback.today/onboarding'); replace this by reading a single shared
base URL constant or environment variable (e.g.,
process.env.NEXT_PUBLIC_BASE_URL or a central config) and compose the onboarding
path from it; prefer using the app's router/navigation method instead of
window.location to avoid full reload and state loss; also audit and update the
extension code to use the same base URL constant (ensuring consistent www vs
non-www handling), and re-check axiosInstance token-expiry redirect logic and
onboarding route guards to ensure internal routing and analytics/tracking
behavior remain correct after the change.
📌 Related Issues
📄 Tasks
⭐ PR Point (To Reviewer)
📷 Screenshot
Summary by CodeRabbit
신규 기능
버그 수정
문서
기타 작업