xhrhelpers
xhrhelpers contains function to help interacting with XHR objects through promises.
Usage
- Use the XHR status
promisifiedXHR ; // Logs the status of the xhr
- Use the XHR response object
promisifiedXHR ; // Logs the response object of the xhr
- Use the XHR response text
promisifiedXHR ; // Logs the response text of the xhr
- Check if the status code was successful (under 299)
promisifiedXHR ; // Throws an error if the status code was > 299
Install it
$ npm install xhrhelpers
Test it
$ npm test