I have a temporarily hidden div (I unhide it later with a radio button) with a dropdown in it that is populated from a callback. When the div is hidden the dropdown is not populated until I trigger the callback again but if I remove ‘display’: ‘none’ and make no other changes it populates fine. Is there a way to populate the dropdown while its hidden and have it retain its values when it’s unhidden?
I’m sorry for the vagaries but I’m a first time poster, I’d be more than happy to post some code (probably the wrong way ha ha) if it helps. But honestly the only change I’m making is removing the display: none.
Maybe try using the CSS property visibility instead, initially set to hidden, and then you can change it visible. This will still render the element, but it will not be visible, as opposed to display:none, which causes the element not to be rendered.