export const getFormState = async (args)=>{
    const { apiRoute, body, serverURL } = args;
    const res = await fetch(`${serverURL}${apiRoute}/form-state`, {
        body: JSON.stringify(body),
        credentials: 'include',
        headers: {
            'Content-Type': 'application/json'
        },
        method: 'POST'
    });
    if (res.ok) {
        const json = await res.json();
        return json;
    }
    return body?.formState;
};

//# sourceMappingURL=getFormState.js.map