logging for the view engine

#1563
Looks fine-ish. Needs docs