I have an application where built a form and i want to setDefaultValue for the form.
I used: const [form] = Form.useForm();. My form tag looks like bellow:
<Form form={form} name="basic" onFinish={onFinish} onFinishFailed={onFinishFailed}>
And i try to set defaultValue:
form.setFieldsValue({
name: object.name,
});
Here i get the next warning: Warning: Instance created by `useForm` is not connect to any Form element. Forget to pass `form` prop?
I saw many answers with this topic, but they solved the issue by adding form={form}. In my case it doesn't work. What could be the issue?