move lookup table out of function to make fn shorter
break up long line
start to generalise form arguments passed through to renderer
remove more duplication
move arg dict where it can be reused
reuse template_args
reuse template_args
Merge commit '47b0' into generalise-importers