Add support for loading templates from a directory