From acb7310fc7fb349074fa02b9adb48985a325cf5a Mon Sep 17 00:00:00 2001 From: yoosangwook Date: Thu, 22 Aug 2024 14:19:39 +0900 Subject: [PATCH] chore: Add ErrorBoundary --- src/app/[locale]/layout.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/app/[locale]/layout.js b/src/app/[locale]/layout.js index c7966ab6..71410d17 100644 --- a/src/app/[locale]/layout.js +++ b/src/app/[locale]/layout.js @@ -2,15 +2,19 @@ import { useCurrentLocale } from '@/locales/client' import { LocaleProvider } from './LocaleProvider' +import ServerError from './error' +import { ErrorBoundary } from 'next/dist/client/components/error-boundary' export default function LocaleLayout({ children }) { const locale = useCurrentLocale() return ( <> - - {children} - + }> + }> + {children} + + ) }