import { UseFormReturn } from "react-hook-form"; export const FormDebug = ({ form }: { form: UseFormReturn }) => { const { watch, formState: { isDirty, dirtyFields, defaultValues }, } = form; const currentValues = watch(); return (

¿Formulario modificado? {isDirty ? "Sí" : "No"}

Campos modificados: {Object.keys(dirtyFields).length > 0 ? ( ) : (

Ninguno

)}
); };