refactor Remove dead code

Remove variables that are created but never used (in some cases, remove
the variable entirely; in some case, just call the method without storing
the result).

Add JSHint build-time check (for `src` files only) for declared but unused vars.

Also, fixes a minor issue that landed in
https://github.com/ariatemplates/ariatemplates/commit/107507a30d0407e46bcbf6dea3cf31ee28c43928#commitcomment-4166998

Close #710. Close #743.