Extracting curl.js from RubyGems folder to it's own folder
Improving curl lib design and adding some tests