pub fn expand_substitution(
substitution: &str,
caps: &Captures<'_>,
params: &[(String, String)],
) -> StringExpand description
Expand $1 / ${name} references against a regex match. Lookup order
for a name: numeric -> pattern capture group by index; otherwise ->
pattern named group, then the route’s {param} path capture; unknown
references expand to the empty string. A lone $ (end of string, or
followed by a non-identifier character) is kept literally.