-
Notifications
You must be signed in to change notification settings - Fork 610
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
Destroy doesn't put original select back #298
Comments
Hey are you able to send me a JSFiddle or a Codepen highlighting the problem please? |
I will when I get some free time. Currently I'm just storing the options for every select before it's instantiated, then putting the original back from my own variables |
I can easily reproduce this as well. It's very inconvenient! Here ya go: |
@DonGissel yep that is exactly the issue. Nice and concise fiddle |
Thanks for the jsfiddle. This isn't so much a bug as it is a missing piece of functionality! Out of interest, would you expect |
Well, it emptying the original That being said, I can see valid points for both restoring original state and persisting the new state. Perhaps a boolean option could be passed to |
I would say this is definitely classified as a bug, since the Docs say that on destroy, the element is put back to its original state as for whether is should revert back to original, or new persisted state, the default in my opinion for a destroy function should be the original state A flag to persist the current state would be helpful however |
@jshjohnson What is the progress on this? |
This has been fixed on the |
When that release is planned to happen... quite keen to get that functionality working, otherwise I'll have to fork it and do it myself |
I also need this functionality to be released. Would be nice to have some kind of timeline. |
This seems to be an issue in 6.0.3, see updated example: https://jsfiddle.net/pco03evt/ Should this be re-opened? |
This is still a glitch in 8.0.0... |
See #574 |
Scenario I have a normal select box with class 'searchable' and normal html options (no ajax).
a choices instance is created:
I destroy the choices instance
NOW, the Docs say that my select tag should be back to its original state.
HOWEVER instead, the select box is left blank (i.e no options in list)
The text was updated successfully, but these errors were encountered: