updates the js files to follow better format practice