Skip to content

Commit

Permalink
fix: disable prefetching to reduce load
Browse files Browse the repository at this point in the history
  • Loading branch information
vnugent committed Dec 4, 2024
1 parent 6815634 commit e370601
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/app/(default)/components/InternationalToC.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const CountryCard: React.FC<{ country: ToCCountry }> = ({ country }) => {
const { areaName, uuid, children } = country
return (
<div className='mb-10 break-inside-avoid-column'>
<Link href={getAreaPageFriendlyUrl(uuid, areaName)}>
<Link prefetch={false} href={getAreaPageFriendlyUrl(uuid, areaName)}>
<span className=' font-semibold'>{areaName}</span>
</Link>
<hr className='mb-2 border-1 border-base-content/60' />
Expand Down
4 changes: 2 additions & 2 deletions src/app/(default)/components/USAToC.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export const USAToC: React.FC = async () => {
return (
<SectionContainer
header={
<Link href={getAreaPageFriendlyUrl('1db1e8ba-a40e-587c-88a4-64f5ea814b8e', 'usa')} className='flex flex-row items-center gap-2'>
<Link prefetch={false} href={getAreaPageFriendlyUrl('1db1e8ba-a40e-587c-88a4-64f5ea814b8e', 'usa')} className='flex flex-row items-center gap-2'>
<h2>USA</h2><ArrowRightCircleIcon className='w-4 h-4' />
</Link>
}
Expand All @@ -21,7 +21,7 @@ export const USAToC: React.FC = async () => {
const { name, uuid, totalClimbs, areas } = state
return (
<div key={name} className='mb-10 break-inside-avoid-column break-inside-avoid'>
<Link href={getAreaPageFriendlyUrl(uuid, name)} className='flex items-end justify-between'>
<Link prefetch={false} href={getAreaPageFriendlyUrl(uuid, name)} className='flex items-end justify-between'>
<span className=' font-semibold'>{name}</span>
<span className='text-xs text-base-content/80'>
{new Intl.NumberFormat().format(totalClimbs)}
Expand Down

0 comments on commit e370601

Please sign in to comment.