moving template data declarations into head