function valueMatches(value, searchText) {
  if (typeof value === 'string') {
    // Value is a string
    // Value contains (ingore case) the search text ?
    return value.toLowerCase().indexOf(searchText.toLowerCase()) !== -1
  }
  return false
}
/**
 * Given value should match the search text
 */
Given value should match the search text
Given value should match the search text
function valueMatches(value, searchText) {
  if (typeof value === 'string') {
    return value.toLowerCase().indexOf(searchText.toLowerCase()) !== -1
  }
  return false
}
function valueMatches ( value , searchText ) { if ( typeof value === 'string' ) { return value . toLowerCase ( ) . indexOf ( searchText . toLowerCase ( ) ) !== - 1 } return false }
Given value should match the search text
Given value should match the search text
// Value is a string // Value contains (ingore case) the search text ?