Add support for template inheritance and partials