2024-03-11 17:33:11 -04:00
|
|
|
use sailfish::RenderOnce;
|
|
|
|
use sailfish_macros::RenderOnce;
|
2020-06-07 08:38:49 -04:00
|
|
|
|
2024-03-11 17:33:11 -04:00
|
|
|
#[derive(RenderOnce)]
|
|
|
|
#[template(path = "foo.stpl", escape = 1)]
|
2020-06-07 08:38:49 -04:00
|
|
|
struct InvalidOptionValue {
|
2024-03-11 17:33:11 -04:00
|
|
|
name: String,
|
2020-06-07 08:38:49 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
2024-03-11 17:33:11 -04:00
|
|
|
println!(
|
|
|
|
"{}",
|
|
|
|
InvalidOptionValue {
|
|
|
|
name: "Hanako".to_owned()
|
|
|
|
}
|
|
|
|
.render_once()
|
|
|
|
.unwrap()
|
|
|
|
);
|
2020-06-07 08:38:49 -04:00
|
|
|
}
|