moved index.js into the lib