Crate truncatable[−][src]
Expand description
truncatable
Truncatable is a simple crate for Strings that should append a follower when truncated (eg, ellipsis)
use truncatable::Truncatable; let to_truncate = Truncatable::from("Hello World!").truncator("~~".into()); assert_eq!(to_truncate.truncate(5), String::from("Hello~~"));
Structs
Truncatable | Main struct, serves as a String wrapper |