-
Notifications
You must be signed in to change notification settings - Fork 1
refactor: 랜딩페이지 web vital 지표 개선 작업 #263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| export default function Head() { | ||
| return ( | ||
| <> | ||
| <link rel="preload" as="image" href="/landing/opening-poster.webp" fetchPriority="high" /> | ||
| </> | ||
| ); | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,16 +1,28 @@ | ||
| import dynamic from 'next/dynamic'; | ||
| import { Header } from '@/shared/components/layout'; | ||
| import { HeaderActions } from '@/composite/landing/headerAction'; | ||
| import { IntroSection } from '@/composite/landing/intro'; | ||
| import { QuestioningSection } from '@/composite/landing/questioning'; | ||
| import { SuggestionSection } from '@/composite/landing/suggestion'; | ||
| import { StoryVideoSection } from '@/composite/landing/storyVideo'; | ||
| import { AddGoalFeatureSection } from '@/composite/landing/addGoal'; | ||
| import { ManageTodoFeatureSection } from '@/composite/landing/manageTodo'; | ||
| import { GoalAdviceFeatureSection } from '@/composite/landing/goalAdvice'; | ||
| import { CollectPlanetFeatureSection } from '@/composite/landing/collectPlanet'; | ||
| import { FundingDiscountSection } from '@/composite/landing/fundingDiscount'; | ||
| import { LaunchSection } from '@/composite/landing/launch'; | ||
| import DonationSection from '@/composite/landing/DonationSection'; | ||
|
|
||
| const QuestioningSection = dynamic(() => import('@/composite/landing/questioning').then(mod => mod.QuestioningSection)); | ||
| const SuggestionSection = dynamic(() => import('@/composite/landing/suggestion').then(mod => mod.SuggestionSection)); | ||
| const StoryVideoSection = dynamic(() => import('@/composite/landing/storyVideo').then(mod => mod.StoryVideoSection)); | ||
| const AddGoalFeatureSection = dynamic(() => | ||
| import('@/composite/landing/addGoal').then(mod => mod.AddGoalFeatureSection) | ||
| ); | ||
| const ManageTodoFeatureSection = dynamic(() => | ||
| import('@/composite/landing/manageTodo').then(mod => mod.ManageTodoFeatureSection) | ||
| ); | ||
| const GoalAdviceFeatureSection = dynamic(() => | ||
| import('@/composite/landing/goalAdvice').then(mod => mod.GoalAdviceFeatureSection) | ||
| ); | ||
| const CollectPlanetFeatureSection = dynamic(() => | ||
| import('@/composite/landing/collectPlanet').then(mod => mod.CollectPlanetFeatureSection) | ||
| ); | ||
| const FundingDiscountSection = dynamic(() => | ||
| import('@/composite/landing/fundingDiscount').then(mod => mod.FundingDiscountSection) | ||
| ); | ||
| const LaunchSection = dynamic(() => import('@/composite/landing/launch').then(mod => mod.LaunchSection)); | ||
| const DonationSection = dynamic(() => import('@/composite/landing/DonationSection').then(mod => mod.default)); | ||
|
Comment on lines
+6
to
+25
|
||
|
|
||
| export default function LandingPage() { | ||
| return ( | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
src/app/head.tsxis the rootheadfor the entire App Router tree, so this preload will run on every route (e.g. auth/home pages) and can waste bandwidth by preloading a landing-only asset. Consider scoping the preload to the landing route by moving the landing page into a route group (e.g.src/app/(landing)/page.tsx) and adding(landing)/head.tsx, or otherwise ensuring the preload is only emitted on/.