FormContext provides a way to share a form state to another components in the tree.
useFormContext is a custom hook, this hook provides the same useForm hook API. If using typescript should pass type of the values.
This hook only will work if there is a parent with FormContext.
More details about React context https://reactjs.org/docs/context.html.