Initial checkin for grade.js and related