gol.js: Add some explanatory comments

...and a minor refactor