2 unstable releases

0.2.0 Nov 7, 2024
0.1.0 Nov 5, 2024

#227 in Template engine

26 downloads per month

MIT license

14KB
280 lines

trivial string templates based on the FORTH word of the same name.

the primary advantage over str::replace is that it can perform multiple replacements while only allocating one new string.

a template is a string that contains several substitutions.

a substitution starts with '%', then has any number of of charachers in its name, then ends with '%'. substitution names are case-sensitive.

a Substituter maps a substitution name to its replacement

the substitution %% always has the replacment %. this is to allow escaping of literal percentage signs.

has no_std support, and can support str and [u8] templates.

No runtime deps

Features