updates to index.js