Use underscore.js, code cleanup, add own stdlib