mirror of
https://github.com/askama-rs/askama.git
synced 2025-12-31 05:41:31 +00:00
That's what the element is called in the template syntax. Also refactor `Generator::visit_attr()` at bit to make it more readable. Also add `__askama` prefix to `_len`.
13 lines
215 B
Rust
13 lines
215 B
Rust
use askama::Template;
|
|
|
|
// Fail on unknown `loop` fields
|
|
|
|
#[derive(Template)]
|
|
#[template(
|
|
source = "{% for _ in 0..10 %} {{ loop.index1 }} {% endfor %}",
|
|
ext = "txt"
|
|
)]
|
|
struct UnknownLoopField;
|
|
|
|
fn main() {}
|