Expands template