pullout getJSPath

Moved it to `utils` folder, and require it for each generator..

Part of the general cleanup tasks in #144