@ In your Use of JavaScript in Moodle reply you wrote:
"At the moment, if anything, the Moodle code has too many inconsistencies. For example, the library that builds the admin tree is completely separate from the forms library, even though they do a similar job."
That's not only the case with core code but even more with the user interface. To build a Moodle theme takes a certain amount of time. And then you need to investigate a huge amount of additional work and time to finetune the theme for many inconsistencies for several core and third party pages.
With templates I could fix for example the module templates once and save a lot of work for future themes. And when customers accept giving back work payed by them I could commit the template changes back to Moodle. And all Moodle themers would benefit.
No, I am not going to try to understand how all the PHP - XHTML mixes work in several Moodle modules. It takes much much more time to understand program logic and presentation parts mixed together than to understand the clearly separated presentation part. Templates would help to build better readable and maintainable code (That is common developer knowledge and experience).
And when third party developers could focus on writing code to handle content and use standard templates to output their content the Moodle user interface would be much more consistent than now. Now many developers try to do web designer work and create huge inconsistencies - not willingly but just by lack of knowledge and experience.