update js for index.html