move page js to index