Split templates to external files