Expand description
Prefix and suffix manipulation utilities.
This module provides functions for working with string prefixes and suffixes, such as conditional appending/prepending.
§Usage
Import the StringAffixes trait to use methods directly on strings:
use rstring::StringAffixes;
assert_eq!("abc".append_if_missing("xyz"), "abcxyz");
assert_eq!("abcxyz".append_if_missing("xyz"), "abcxyz");Traits§
- String
Affixes - Extension trait for prefix and suffix manipulation methods.