You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Essentially, everywhere there is an instance of name = 'someContent' ref={register}, we should instead have name = 'someContent' {...register('someContent', { required: true })}
In /admin/[slug].js
Error 1:
const { register, errors, handleSubmit, formState, reset, watch } = useForm({ defaultValues, mode: 'onChange' });
should be changed to
const { register, handleSubmit, formState, reset, watch, formState: { errors } } = useForm({ defaultValues, mode: 'onChange' });
Error 2:
should be changed to
Error 3:
<input className={styles.checkbox} name="published" type="checkbox" ref={register} />
should be changed to
The text was updated successfully, but these errors were encountered: