-
-
Notifications
You must be signed in to change notification settings - Fork 5.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ReferenceInput throws "Cannot fetch a reference to "myresource" (unknown resource)." #4996
Comments
I'm also facing this issue. The first time that I open a page using the custom route, it works. But if I refresh the page, I get this error. <Create resource="competitions" basePath="/competitions" >
<SimpleForm>
<ReferenceInput label="Challenge" reference="challenges" source="id">
<AutocompleteInput optionText="task" />
</ReferenceInput>
</SimpleForm>
</Create> |
Thanks for reporting this. If you are able to illustrate the bug or feature request with an example, please provide a sample application by forking the following CodeSandbox (https://codesandbox.io/s/github/marmelab/react-admin/tree/master/examples/simple). |
@djhi Also, accessing this route Configuration Route directly inside the sandbox browser, you'll get the same issue. |
Reproduced. Thanks |
What you were expecting:
I declared
myresource
and when I was on 3.3.3, my page worked as expected. (butuseQueryWithStore
returned a null total.What happened instead:
Now that I upgraded to 3.4.0,
useQueryWithStore
returns the right total but on first page load (custom route withReferenceInput
) I have an error :Steps to reproduce:
I'll make a sandbox tomorrow and try to figure out which version introduced the regression.
Other information:
Environment
The text was updated successfully, but these errors were encountered: