Add programatic modal support for rendering templates with no views