add templates and index