pub fn substr(input: &str, start: usize, length: usize) -> StringExpand description
Unicode-safe substring.
Respects Unicode codepoints but is not grapheme-cluster aware (combining characters like skin-tone modifiers count as separate codepoints).
use oxios_markdown::parser::substr;
assert_eq!(substr("Hello", 0, 3), "Hel");
assert_eq!(substr("Hello", 3, 10), "lo");
assert_eq!(substr("Hello", 10, 2), "");