Files
sam-react-prod/src/contexts/AuthContext.tsx

26 lines
756 B
TypeScript
Raw Normal View History

'use client';
/**
* AuthContext - re-export
*
* src/stores/authStore.ts (Zustand) .
* import { useAuth } from '@/contexts/AuthContext'
* re-export.
*/
import { type ReactNode } from 'react';
import { useAuthStore } from '@/stores/authStore';
// 타입 re-export
export type { Tenant, Role, MenuItem, User, UserRole } from '@/stores/authStore';
// AuthProvider: 빈 passthrough (미발견 import 안전망)
export function AuthProvider({ children }: { children: ReactNode }) {
return <>{children}</>;
}
// useAuth: authStore 전체 상태를 반환 (기존 Context 인터페이스 유지)
export function useAuth() {
return useAuthStore();
}