Name: request-promise-any
Owner: request
Description: The simplified HTTP request client 'request' with Promise support. Powered by 'any-promise'.
Created: 2016-05-06 20:56:27.0
Updated: 2018-04-02 17:06:39.0
Pushed: 2017-09-22 17:02:27.0
Size: 19
Language: JavaScript
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
<img src="https://promises-aplus.github.io/promises-spec/assets/logo-small.png" align="right" alt="Promises/A+ logo" />
This package is similar to request-promise
but uses any-promise
to let the user choose which Promise library to use.
Please refer to the request-promise
documentation. Everything applies to request-promise-any
except the following:
.finally(...)
method is not available.This module is installed via npm:
install --save request
install --save request-promise-any
request
is defined as a peer-dependency and thus has to be installed separately.
First, install your preferred Promise library. E.g. Q:
install --save q
Then, register the Promise library before you require request-promise-any
for the first time:
ire('any-promise/register/q')
rp = require('request-promise-any')
For a list of supported Promise libraries and advanced registration features read the documentation of any-promise
.
request-promise
to request-promise-any
request-promise
v4..finally(...)
anymore.To set up your development environment:
cd
to the main folder,npm install
,npm install gulp -g
if you haven't installed gulp globally yet, andgulp dev
. (Or run node ./node_modules/.bin/gulp dev
if you don't want to install gulp globally.)gulp dev
watches all source files and if you save some changes it will lint the code and execute all tests. The test coverage report can be viewed from ./coverage/lcov-report/index.html
.
If you want to debug a test you should use gulp test-without-coverage
to run all tests without obscuring the code by the test coverage instrumentation.
tough-cookie
to a version without regex DoS vulnerability
(Thanks to @rouanw and @sophieklm for their pull requests request-promise#226 and request-promise-native#13)tough-cookie
for cookie creation@request/promise-core
version for safer versioningrequest-promise
v4In case you never heard about the ISC license it is functionally equivalent to the MIT license.
See the LICENSE file for details.