removeWhiteSpace function

String removeWhiteSpace(
  1. dynamic str
)

Implementation

String removeWhiteSpace(str) {
  if (str.length <= 0) return '';
  return str.trim().replaceAll(RegExp(r'\s+'), '');
}