adding templates and routing