Remove logs, dead code, and duplication.
Start templating client side.