#string #truncate #human

ellipse

Truncate and ellipse strings in a human-friendly way

2 unstable releases

0.2.0 Apr 22, 2019
0.1.0 Apr 17, 2019

#1052 in Text processing

Download history 288/week @ 2024-07-24 239/week @ 2024-07-31 208/week @ 2024-08-07 203/week @ 2024-08-14 274/week @ 2024-08-21 660/week @ 2024-08-28 608/week @ 2024-09-04 589/week @ 2024-09-11 510/week @ 2024-09-18 417/week @ 2024-09-25 338/week @ 2024-10-02 335/week @ 2024-10-09 297/week @ 2024-10-16 267/week @ 2024-10-23 328/week @ 2024-10-30 174/week @ 2024-11-06

1,146 downloads per month
Used in 6 crates

MIT/Apache

5KB

ellipse

Travis CI Status crates.io Documentation

Truncate and ellipse strings in a human-friendly way. Uses unicode extended grapheme clusters.

Documentation

Example

use ellipse::Ellipse;

let input = "🇩🇪🇬🇧🇮🇹🇫🇷";
assert_eq!(&input.truncate_ellipse(2), "🇩🇪🇬🇧...");

License

Licensed under either of

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~355KB