removeWhiteSpace method

String removeWhiteSpace(
  1. String str
)

Removes all whitespace from provided string. 从提供的字符串中删除所有空格。

Implementation

String removeWhiteSpace(String str) {
  return str.replaceAll(RegExp(r"\s+"), "");
}