Pass gjslint

This PR tidies libtess.js to pass the [Closure Linter](https://developers.google.com/closure/utilities/) in `--strict` mode with the exception of line lengths (some lines are > 80 characters).