* [@types/request] Fill out Request and Response.
This hold much more true to the actual lib where a `Request` and
`Response` reference each other and the `Request` has most of the
provided options merged onto it, plus other stuff.
Makes use of the newly added `@types/caseless` to DRY up some of the
header work.
Updated version reference from 2.0 to 2.47 to cover both the addition of
`caseless` and the removal of `getAgent` from the lib.
I have a project that uses `request-promise-native`, these changes work
in my testing and having the `Response` object typed allowed me to
remove all my declaration merging files from the `request` namespace.
* [@types/request] Update promise sub-libs.
Update `request-promise` and `request-promise-native` to use new
`Response` interface.
I had two PRs merge close together that caused the build to fail.
- #22809 fixed a bug
- #22821 removed all the overrides from `tslint.json`
Unfortunately, the former ended up with a couple lint issues.
```
./types/request/index.d.ts
ERROR: 64:20 unified-signatures This overload and the one on line 63
can be combined into one signature taking `string | RequiredUriUrl &
TOptions`.
./types/request/request-tests.ts
ERROR: 10:5 prefer-const Identifier 'value' is never
reassigned; use 'const' instead of 'let'.
```
Although not specified on the main page, as per
b12a6245d9/tests/browser/test.js we can see that this is part of the request module.
More practically: local testing shows adding the {withCredentials:false} option allows us to create a request that accepts an "*" value for the Access-Control-Allow-Origin header.