equalsIgnoreCase method

  1. @useResult
bool equalsIgnoreCase(
  1. String other
)

Returns true if this and other are equal, ignoring capitalization.

'aBc'.equalsIgnoreCase('abC'); // true

'aB'.equalsIgnoreCase('aC'); // false

Implementation

@useResult bool equalsIgnoreCase(String other) => toLowerCase() == other.toLowerCase();