diff --git a/apps/web/src/app/layout.tsx b/apps/web/src/app/layout.tsx index aefae93..0f2822d 100644 --- a/apps/web/src/app/layout.tsx +++ b/apps/web/src/app/layout.tsx @@ -11,7 +11,7 @@ import AuthProvider from '@/auth'; // import LoadingOverlay from '@/components/LoadingOverlay'; import MessageDialog from '@/components/messageDialog'; import '@/globals.css'; -import { PostHogProvider } from '@/posthog'; +// import { PostHogProvider } from '@/posthog'; import QueryProvider from '@/query'; const isDevelopment = process.env.NODE_ENV === 'development'; @@ -132,13 +132,14 @@ export default function RootLayout({ - {isDevelopment ? ( + + {/* {isDevelopment ? ( ) : ( - )} + )} */} diff --git a/apps/web/src/auth.tsx b/apps/web/src/auth.tsx index 70b8e20..ec5dd91 100644 --- a/apps/web/src/auth.tsx +++ b/apps/web/src/auth.tsx @@ -17,10 +17,9 @@ export default function AuthProvider({ children }: { children: React.ReactNode } const currentPathRef = useRef(pathname); useEffect(() => { - const isPublicPath = ALLOW_PATHS.includes(pathname); - // 경로가 변경되면 체크 상태 리셋 if (currentPathRef.current !== pathname) { + console.log(currentPathRef.current); setIsAuthChecked(false); redirectingRef.current = false; currentPathRef.current = pathname; @@ -31,11 +30,10 @@ export default function AuthProvider({ children }: { children: React.ReactNode } return; } - // 공개 경로는 바로 통과 - if (isPublicPath) { - setIsAuthChecked(true); - return; - } + // if (isPublicPath) { + // setIsAuthChecked(true); + // return; + // } // 이미 인증된 상태면 바로 통과 (하지만 체크는 수행) const handleAuth = async () => { diff --git a/apps/web/src/stores/useAuthStore.ts b/apps/web/src/stores/useAuthStore.ts index 633fed3..181a6f6 100644 --- a/apps/web/src/stores/useAuthStore.ts +++ b/apps/web/src/stores/useAuthStore.ts @@ -101,9 +101,9 @@ const useAuthStore = create( const { error } = await supabase.auth.signInWithOAuth({ provider: 'kakao', - options: { - redirectTo: `${process.env.NEXT_PUBLIC_APP_URL}`, - }, + // options: { + // redirectTo: `${process.env.NEXT_PUBLIC_APP_URL}`, + // }, }); if (error) throw error;