@emsipl/react-select-search
Version:
Fork of https://github.com/tbleckert/react-select-search
18 lines (14 loc) • 360 B
JavaScript
;
exports.__esModule = true;
exports["default"] = getDisplayValue;
function getDisplayValue(value) {
if (value && typeof value === 'object') {
if (Array.isArray(value)) {
return value.map(function (singleOption) {
return singleOption && singleOption.name;
}).join(', ');
}
return value.name;
}
return '';
}