Skip to main content

trim_start

Function trim_start 

Source
pub fn trim_start(s: &str, chars_to_trim: Option<&str>) -> String
Expand description

Trim specified characters from the start of a string

ยงExamples

use mudssky_utils::string::trim_start;

assert_eq!(trim_start("  hello world  ", None), "hello world  ");
assert_eq!(trim_start("__hello__", Some("_")), "hello__");