Documentation updated for main.js and globals.js