How does my user deselect/unselect/undo his selected value?

In my select2 input is not required. When a user makes a selection but wants the selection to be undone. How does he accomplish that.

For instance at https://select2.org/appearance I select Hawaii but I want to undo my selection so nothing is selected. How do I do that?

It’s documented here: https://select2.org/selections#clearable-selections.

1 Like

Thanks John30013!

I’ve found out that in version 3.x.x I also needed to add an empty option tag to make it work.
<option></option>

1 Like