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
It shows tree components:
1- Labeled + FunctionField. => It works but with a warning for not using getSource
2- Labeled + TextField passing source='url' and record={scopedFormData}. => It works but with a warning for not using getSource
3- Labeled + TextField with source=getSource('url'). => Shows the data but doesn't change when an input of the same source changes (merged in #8359)
Reproduction:
1- Edit the Post of id=1 and click in Miscellaneous Tab.
2- In the Backlinks ArrayInput, type into the URL input to see the results
The text was updated successfully, but these errors were encountered:
I just tested solution 2 without passing the extra props, and it seems to be working too.
Can you confirm on your end?
If this is confirmed, then we should go for this solution, and maybe get rid of the warning (plus perhaps update the docs to explain that getSource is a useful helper but you loose reactivity when using it).
Related to #8359
None of the possible solutions work correctly when using a
Field
inside aSimpleFormIterator
.I put together a Stackblitz (https://stackblitz.com/edit/github-stqpcj?file=src%2Fposts%2FPostEdit.tsx) to show what I mean.
It shows tree components:
1-
Labeled
+FunctionField
. => It works but with a warning for not usinggetSource
2-
Labeled
+TextField
passingsource='url'
andrecord={scopedFormData}
. => It works but with a warning for not usinggetSource
3-
Labeled
+TextField
withsource=getSource('url')
. => Shows the data but doesn't change when an input of the same source changes (merged in #8359)Reproduction:
1- Edit the Post of id=1 and click in Miscellaneous Tab.
2- In the Backlinks
ArrayInput
, type into the URL input to see the resultsThe text was updated successfully, but these errors were encountered: