datalist-polyfill.js
function(input) {
		// In case of type=email and multiple attribute, we would need to grab the last piece
		// Using .getAttribute here for IE9 purpose - elsewhere it wouldn't return the newer HTML5 values correctly
		return input.getAttribute('type') === 'email' &&
			input.getAttribute('multiple') !== null
			? input.value.substring(input.value.lastIndexOf(',') + 1)
			: input.value;
	}
function(input) {
		// In case of type=email and multiple attribute, we would need to grab the last piece
		// Using .getAttribute here for IE9 purpose - elsewhere it wouldn't return the newer HTML5 values correctly
		return input.getAttribute('type') === 'email' &&
			input.getAttribute('multiple') !== null
			? input.value.substring(input.value.lastIndexOf(',') + 1)
			: input.value;
	}
function ( input ) { // In case of type=email and multiple attribute, we would need to grab the last piece // Using .getAttribute here for IE9 purpose - elsewhere it wouldn't return the newer HTML5 values correctly return input . getAttribute ( 'type' ) === 'email' && input . getAttribute ( 'multiple' ) !== null ? input . value . substring ( input . value . lastIndexOf ( ',' ) + 1 ) : input . value ; }
Get the input value for dividing regular and mail types
Get the input value for dividing regular and mail types