Replies: 1 comment
-
Here you go: All my virtualSelect components have the classes i'm query selecting below. Then and in order to safeguard, i am checking whether the domElement is an instance of virtualSelect (checking for undefined type). In such case i have a return otherwise i am using the destroy function.
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I cannot figure out how to use the
destroy()
function. The example in the documentation is pretty minimal but I figured it should be straightforward to use. But no matter what I try, I get some variation ofUncaught (in promise) TypeError: sampleMenu.destroy is not a function
in the browser console. I've tried different ways to access the Virtual Select part of the element to use the actualdestroy()
method, but I've run out of ideas that aren't stabs in the dark.I'm trying to reinitialize an existing menu with a larger set of options, and simply setting the options to a new set doesn't work; the
setOptions()
method doesn't tell the drop-down menu to refresh correctly and the scrollable length doesn't expand from the previous smaller size. So I'm now trying to destroy and reinitialize the menu instead, but I cannot access thedestroy()
function. What am I missing?Beta Was this translation helpful? Give feedback.
All reactions