Recreated the template view engine from scratch