#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

#1097 in Text processing

Download history 496/week @ 2024-11-19 492/week @ 2024-11-26 431/week @ 2024-12-03 613/week @ 2024-12-10 404/week @ 2024-12-17 76/week @ 2024-12-24 146/week @ 2024-12-31 484/week @ 2025-01-07 656/week @ 2025-01-14 395/week @ 2025-01-21 406/week @ 2025-01-28 563/week @ 2025-02-04 601/week @ 2025-02-11 410/week @ 2025-02-18 363/week @ 2025-02-25 113/week @ 2025-03-04

1,581 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