extract JS and default content from index.html