Expand description
Truncate and ellipse strings in a human-friendly way.
Uses unicode extended grapheme clusters.
ยงExample
use ellipse::Ellipse;
let input = "๐ฉ๐ช๐ฌ๐ง๐ฎ๐น๐ซ๐ท";
assert_eq!(&input.truncate_ellipse(2), "๐ฉ๐ช๐ฌ๐ง...");
Traitsยง
- Truncate and ellipse strings in a human-friendly way.