I just ported some code from Python to Rust, and spent a good few days pouring over the template/DOM ecosystem. What I really wanted was a Rust version of Python's Dominate library, which allows you to write your DOM nodes as regular objects and render the tree with nice (locally controllable) indentation. I didn't want templates, and I wanted something that allowed me to control indentation, leave comments in the HTML, and write code as code. I ended up spending a week implementing something similar to Dominate in Rust.
https://github.com/Knio/dominate