breakWord static method

String breakWord(
  1. String text
)

使文字在任意位置换行

Implementation

static String breakWord(String text) {
  if (text.isEmpty) {
    return text;
  }
  return text.replaceAll("", "\u200B");
}