added notes to the js file