examples/dropdown/dist/index.js
function getDefaultValue(customSelect) {
    var val = customSelect.getAttribute('value');
    if (val === null) {
      return '';
    }
    var firstChar = val[0];
    if (firstChar === undefined) {
      return '';
    } else if (firstChar === '[') {
      return JSON.parse(val);
    }
    return val;
  }
function getDefaultValue(customSelect) {
    var val = customSelect.getAttribute('value');
    if (val === null) {
      return '';
    }
    var firstChar = val[0];
    if (firstChar === undefined) {
      return '';
    } else if (firstChar === '[') {
      return JSON.parse(val);
    }
    return val;
  }
function getDefaultValue ( customSelect ) { var val = customSelect . getAttribute ( 'value' ) ; if ( val === null ) { return '' ; } var firstChar = val [ 0 ] ; if ( firstChar === undefined ) { return '' ; } else if ( firstChar === '[' ) { return JSON . parse ( val ) ; } return val ; }
Get default value from value="" attribute
which might be a string representing a single selected option value
or a JSON array representing selected options in multiple select

This attribute has highest priority over aria-selected which will be updated in syncUI()
If value is empty string or no value attribute found then 1st option is selected

@param customSelect
@returns {String|Array}
Get default value from value = attribute which might be a string representing a single selected option value or a JSON array representing selected options in multiple select