This is interesting.
I wish this would become part of HA itself, with better integration, like editing the templates from the UI.
Please check my WTH post here: WTH - Adding native support to reusable sections with substitution parameters (Lovelace_gen but easier)