Releases: ladjs/superagent
Releases · ladjs/superagent
v2.0.0
Breaking changes
Breaking changes are in rarely used functionality, so we hope upgrade will be smooth for most users.
- Browser: The
.parse()
method has been renamed to.serialize()
to avoid inconsistency with NodeJS version (v1.8.3 supports.serialize()
too) - Browser: Query string keys without a value used to be parsed as
'undefined'
, now their value is''
(empty string) (shura, Kornel Lesiński). - NodeJS: The
redirect
event is called after new query string and headers have been set and is allowed to override the request URL (Kornel Lesiński) .then()
returns a realPromise
. Note that use of superagent with promises now requires a globalPromise
object.
If you target Internet Explorer or Node 0.10, you'll needrequire('es6-promise').polyfill()
or similar.- Upgraded all dependencies (Peter Lyons)
- Renamed properties documented as
@api private
to have_prefixed
names (Kornel Lesiński)
Probably not breaking changes:
- Extracted common functions to request-base (Peter Lyons)
- Fixed race condition in pipe tests (Peter Lyons)
- Handle
FormData
error events (scriptype) - Fixed wrong jsdoc of Request#attach (George Chung)
- Updated and improved tests (Peter Lyons)
2.0.0-alpha.1
v1.8.2
- Fixed handling of HTTP status 204 with content-encoding: gzip (Andrew Shelton)
- Handling of FormData error events (scriptype)
- Fixed parsing of
vnd+json
MIME types (Kornel Lesiński) - Aliased browser implementation of
.parse()
as.serialize()
for forward compatibility
v1.8.0
- Extracted common code into request-base class (Peter Lyons)
- It does not affect the public API, but please let us know if you notice any plugins/subclasses breaking!
- Added option
{type:'auto'}
toauth
method, which enables browser-native auth types (Jungle, Askar Yusupov) - Added
responseType()
to set XHRresponseType
(chris) - Switched to form-data for browserify-compatible
FormData
(Peter Lyons) - Added
statusCode
to error response when JSON response is malformed (mattdell) - Prevented TCP port conflicts in all tests (Peter Lyons)
- Updated form-data dependency
1.8.0-beta.2
v1.7.2
v1.7.1
v1.7.0
- when attaching files, read default filename from the
File
object (JD Isaacks) - add
direction
property toprogress
events (Joseph Dykstra) - update component-emitter & formidable (Kornel Lesiński)
- don't re-encode query string needlessly (Ruben Verborgh)
- ensure querystring is appended when doing
stream.pipe(request)
(Keith Grennan) - change set header function, not call
this.request()
until callthis.end()
(vicanso) - add no-op
withCredentials
to Node API (markdalgleish) - fix
delete
breaking on ie8 (kenjiokabe) - don't let request error override responses (Clay Reimann)
- increased number of tests shared between node and client (Kornel Lesiński)
v1.6.1
(same as v1.6.0, but needed re-publishing to npm)
- avoid misleading CORS error message
- add 'progress' event on file/form upload in Node (Olivier Lalonde)
- return raw response if the response parsing fails (Rei Colina)
- parse content-types ending with
+json
as JSON (Eiryyy) - fix to avoid throwing errors on aborted requests (gjurgens)
- retain cookies on redirect when hosts match (Tom Conroy)
- add Bower manifest (Johnny Freeman)
- upgrade to latest cookiejar (Andy Burke)