askama-minify 0.3.1

A procedural macro for minifying Askama templates at compile time
Documentation
1
2
3
4
5
6
7
8
9
10
11
pub(super) fn trim_trailing_space(value: &mut String) {
    if value.ends_with(' ') {
        value.pop();
    }
}

pub(super) fn trim_trailing_whitespace(value: &mut String) {
    while value.chars().next_back().is_some_and(char::is_whitespace) {
        value.pop();
    }
}