Updated project structure and ported the code to javascript.
Updated the readme.