Added AMD and CommonJS module compatibility with Curl JS example.