Initial work toward making templates expandable