Skip to content

Commit

Permalink
fix: lazy loading으로 프리렌더링 빌드 에러 컴포넌트들 SSR 불허
Browse files Browse the repository at this point in the history
  • Loading branch information
HiimKwak committed Nov 28, 2023
1 parent 2e4e4b6 commit 09fbb6d
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/app/admin/league/page.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,18 @@
'use client';

import dynamic from 'next/dynamic';
import Link from 'next/link';
import { Suspense } from 'react';

import LeagueList from '@/components/admin/league/LeagueList';
import Button from '@/components/common/Button';
import LeagueListFetcher from '@/queries/admin/useLeagueList/Fetcher';

const LeagueListFetcher = dynamic(
() => import('@/queries/admin/useLeagueList/Fetcher'),
{ ssr: false },
);
const LeagueList = dynamic(
() => import('@/components/admin/league/LeagueList'),
);

export default function LeaguePage() {
return (
Expand Down

0 comments on commit 09fbb6d

Please sign in to comment.