Skip to content

#1 PDF Application on GitHub that lets you edit PDFs on any device anywhere

446 B
Raw Blame
import { useAuth } from "@editor/auth/UseSession";
import type { AccountCreatedAt } from "@editor-cloud/components/onboarding/accountCreatedAt";

export type { AccountCreatedAt } from "@editor-cloud/components/onboarding/accountCreatedAt";

export function useAccountCreatedAt(): AccountCreatedAt {
  const { user, loading } = useAuth();
  const createdAt = user?.created_at ? new Date(user.created_at) : null;
  return { loading, createdAt };
}