leftTrim method

String leftTrim([
  1. String? chars
])

Trims characters from the left side of the string.

Implementation

String leftTrim([String? chars]) => (chars != null)
    ? replaceAll(RegExp('^[$chars]+'), '')
    : replaceAll(RegExp(r'^\s+'), '');