-
I am working on a project, implemented This is my Select component:
Is use it followings:
Where
I am able to fix it adding But it still does not work. Could somebody give me some hint? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
After hours I think the problem was a race condition, since the Select component is re-rendered once the async items are loaded but the options elements are not, or something like that. I tested it setting the items static, no async load and no re-render of the components, and it worked. I decided to move the rendering of the options into the select component and omitting the children:
If somebody has a solution using the option elements as children, please let me know. |
Beta Was this translation helpful? Give feedback.
After hours I think the problem was a race condition, since the Select component is re-rendered once the async items are loaded but the options elements are not, or something like that. I tested it setting the items static, no async load and no re-render of the components, and it worked. I decided to move the rendering of the options into the select component and omitting the children: