Does not support empty options
marcomarsala opened this issue · comments
Steps to reproduce
Tell us how to reproduce this issue.
Insert an empty option like this:
<option value=" "></option>
or like this:
<option value=" "> </option>
in a select
Demo: https://jsfiddle.net/d7crx2f5/
Expected behavior
The empty option should be displayed like all other options.
Actual behavior
The empty option is not displayed.
Environment
-
Chosen Version: 1.8.7
-
jQuery or Prototype Version: jQuery 3.2.1
-
Browser and Version: Chrome 86
-
OS and Version: Windows 7
Additional information
If you write the empty option as <option value=" "> </option>
it works.
You can do it very easily - change order your options: empty option must first on list
Demo:
https://jsfiddle.net/yhrmxgso/2/