helpers.js
function toUniqueStrings(input) {
  const list = (Array.isArray(input) ? input : [input])
    .map(el => (typeof el === 'string' ? el.trim() : null))
    .filter(Boolean)
  return list.length > 1 ? Array.from(new Set(list)) : list
}
function toUniqueStrings(input) {
  const list = (Array.isArray(input) ? input : [input])
    .map(el => (typeof el === 'string' ? el.trim() : null))
    .filter(Boolean)
  return list.length > 1 ? Array.from(new Set(list)) : list
}
function toUniqueStrings ( input ) { const list = ( Array . isArray ( input ) ? input : [ input ] ) . map ( el => ( typeof el === 'string' ? el . trim ( ) : null ) ) . filter ( Boolean ) return list . length > 1 ? Array . from ( new Set ( list ) ) : list }
Return an array of unique trimmed strings,
from input which can be a string or an array of strings
@param {Array|string} input
@return {string[]}
Return an array of unique trimmed strings from input which can be a string or an array of strings