How can I use useFormik hook with ` ?
I tried this but not working
const formik = useFormik({
initialValues: {
healthBackground: [],
},
onSubmit: (values) => alert(JSON.stringify(values)),
});
return (
<formik>
<input type="checkbox" {...formik.getFieldProps("healthBackground")} value="test1" />
<input type="checkbox" {...formik.getFieldProps("healthBackground")} value="test2" />
</formik>
)