add a module with the same name as each file, ie. role.js -> var ROLE = require("role");
AutoComplete for JS https://github.com/Garethp/ScreepsAutocomplete
in a node command prompt:
cd {screeps-bs-path}
npm install grunt
npm install grunt-cli
npm install grunt-screeps
npm install grunt-contrib-watch
grunt watch