UNPKG

@adonis-agora/authkit-react

Version:

Frontend ergonomics over AuthKit for AdonisJS + Inertia + React apps: a typed useAuth() hook, role-gating hooks and gating components.

6 lines (5 loc) • 185 B
export function isLastUsedLoginMethod(lastUsed, methods) { if (!lastUsed) return false; return (typeof methods === 'string' ? [methods] : methods).includes(lastUsed); }