UNPKG

@replyke/core

Version:

Replyke: Build interactive apps with social features like comments, votes, feeds, user lists, notifications, and more.

16 lines 643 B
import { useCallback } from "react"; import axios from "../../config/axios"; import useProject from "../projects/useProject"; function useSendVerificationEmail() { const { projectId } = useProject(); const sendVerificationEmail = useCallback(async (props) => { if (!projectId) { throw new Error("No projectId available."); } const response = await axios.post(`/${projectId}/auth/send-verification-email`, props ?? {}); return response.data; }, [projectId]); return sendVerificationEmail; } export default useSendVerificationEmail; //# sourceMappingURL=useSendVerificationEmail.js.map