pub fn parameterize(text: &str, preserve_case: bool) -> StringExpand description
Rails String#parameterize, the one GitLab calls.
In order: transliterate to an ASCII approximation, replace every run
of characters outside [A-Za-z0-9_-] with -, squeeze repeated
separators into one, drop a leading and a trailing separator, and
downcase unless the case is preserved.