remove un-used js, move the rest to the bottom of the body