David Frank
05f8de4548
Merge pull request #276 from bitinn/readme-update
...
Mention 2.x alpha in the main readme
2017-05-15 20:34:01 +08:00
David Frank
38d75d5a1f
Mention 2.x alpha in the main readme
2017-05-15 20:24:52 +08:00
David Frank
9cea8719eb
Merge pull request #275 from bitinn/v2-alpha-4
...
2.0.0 alpha 4
2017-05-15 20:09:24 +08:00
David Frank
2d986a7999
get ready for alpha 4 release
2017-05-15 19:47:12 +08:00
David Frank
770388db1b
only enable Z_SYNC_FLUSH for gzip response
2017-05-15 19:45:04 +08:00
David Frank
2a1a565641
Merge pull request #271 from bitinn/fix-package-json
...
Use full filename at browser field
2017-05-12 13:10:40 +08:00
David Frank
a170290460
Use full filename at browser field
2017-05-12 13:04:51 +08:00
David Frank
1dba86665a
Merge pull request #264 from m59peacemaker/master
...
use browser natives when bundled for the browser
2017-05-12 13:00:44 +08:00
David Frank
7fb7ea52a8
Merge pull request #267 from AlexTes/patch-1
...
Document response.ok convenience property
2017-05-12 12:09:04 +08:00
David Frank
524d237e55
Merge pull request #269 from AlexTes/patch-2
...
Small improvements to the error-handling wording
2017-05-12 12:07:15 +08:00
Alexander Tesfamichael
1797181feb
Small improvements to the error-handling wording
2017-05-11 10:02:28 +02:00
Alexander Tesfamichael
70e8483ac6
Document response.ok convenience property
2017-04-30 19:59:33 +02:00
Johnny Hauser
5f02f36500
use browser natives when bundled for the browser
2017-04-09 13:42:50 -05:00
Kat Marchán
e5ff203ef4
Revert "Allow passing agent option as an object ( #236 )" ( #263 )
...
This reverts commit ec29e3d264
.
This patch prevents any agent being passed in which is not explicitly
an instance of `http.Agent`. This makes `node-fetch` no longer
compatible with https://npm.im/proxy-agent , which is one example of a
library that does not directly inherit from `http.Agent` directly.
Sorry for the revert -- I don't have an alternative patch because I
don't believe this is something node-fetch should be doing
automatically, because of how much of a limitation this could impose.
The original PR stated that this was to prevent requiring http/https,
and the effect would effectively be to force creation of an Agent on
every call. Note that this is already the behavior specified for
http.Agent when http.request received `false`. (See the bottom of the
[section on http.Agent in the Node
docs](https://nodejs.org/dist/latest-v7.x/docs/api/http.html#http_class_http_agent ).
Cheers, and with apologies to @ahmadnassri for reverting their PR.
2017-04-08 18:33:46 -07:00
Ahmad Nassri
ec29e3d264
Allow passing agent option as an object ( #236 )
2017-04-03 02:54:31 -07:00
Kat Marchán
09f2e30557
headers.get: add space to join ( #257 )
...
The behavior was changed in whatwg/fetch#504 .
2017-04-02 08:43:46 -07:00
Gajus Kuizinas
4804a40c17
Add a special case for constructing Headers with Headers ( #253 )
...
Fixes : #251 .
2017-03-20 09:22:49 -07:00
Grzegorz Graczyk
a1e76b97e1
More lenient gzip decompression ( #239 )
...
Ref: https://github.com/nodejs/node/issues/8701#issuecomment-268224481
Ref: https://github.com/request/request/issues/2482
Ref: https://github.com/request/request/pull/2492
Fixes: http://www.mantovanispa.it
Fixes : #139
2017-02-27 10:02:45 -08:00
Timothy Gu
047799b742
Remove babel-plugin-transform-runtime
2017-02-26 21:56:29 -08:00
Timothy Gu
da159b9547
Prettify .babelrc
2017-02-26 21:54:54 -08:00
Timothy Gu
eb1959ed09
Drop babel-runtime
...
Fixes #243 .
2017-02-26 21:46:53 -08:00
Timothy Gu
397eab7757
compress: use spec nomenclature
2017-02-26 21:27:27 -08:00
Tino Vyatkin
f0d0675d00
Remove unneeded is-stream and buffer-to-arraybuffer ( #241 )
2017-02-26 18:29:57 -08:00
Timothy Gu
e284841db9
test: use fetch.Promise consistently
...
On Node.js v4, Babel polyfills `Promise`.
2017-02-26 17:00:01 -08:00
Timothy Gu
a345c398b3
More documentation
2017-02-26 16:52:32 -08:00
Timothy Gu
25e43a8f3e
Export FetchError and update ERROR-HANDLING.md
2017-02-26 16:46:34 -08:00
Timothy Gu
55e573b741
Back to 100% coverage
2017-02-26 15:30:43 -08:00
Timothy Gu
b899649c32
Remove bluebird
2017-02-26 14:42:46 -08:00
Timothy Gu
9e140039ac
Factor out Body mixin
2017-02-26 14:42:09 -08:00
Timothy Gu
f08b120771
Do not inherit from body
...
Per spec, make Body a proper mixin
2017-02-26 14:29:40 -08:00
Timothy Gu
56f786f896
Update deps and remove 0.12 compat
2017-02-26 14:12:45 -08:00
Timothy Gu
a10f5786bd
Consolidate CHANGELOG
2017-02-26 13:50:38 -08:00
Timothy Gu
67678a9a54
Update UPGRADE-GUIDE
2017-02-26 13:45:25 -08:00
Timothy Gu
d23204b4ec
README: remove trailing whitespace
2017-02-26 13:18:41 -08:00
Tino Vyatkin
edb28a6c50
Drop Node.js v0.12 support ( #240 )
2017-02-26 13:17:47 -08:00
Ahmad Nassri
673ebb2089
docs(defaults): list of default header values ( #237 )
...
Fixes #226 .
2017-02-21 12:38:54 -08:00
Timothy Gu
560d5d6a02
2.0.0-alpha.3
2017-01-29 10:35:31 -08:00
Timothy Gu
11a9481405
request: overwrite Content-Length if possible
...
Also reorganize header normalization
2017-01-29 10:06:54 -08:00
Timothy Gu
ac8ddaccb8
Improve Headers constructor argument processing
2017-01-29 08:58:16 -08:00
Timothy Gu
db733374dd
Fix CHANGELOG for v2.0.0-alpha.2
...
[ci skip]
2017-01-28 08:42:17 -08:00
Timothy Gu
e9db869523
Remove FOLLOW_SPEC option; make it the default behavior ( #225 )
...
* Remove !FOLLOW_SPEC mode
* Update UPGRADE-GUIDE
* Add CHANGELOG entry
2017-01-23 07:54:28 -08:00
Timothy Gu
95bf356c4d
Use babel-preset-env
2017-01-22 17:14:55 -08:00
Timothy Gu
7539115bcc
Silent rollup warning
2017-01-22 17:08:11 -08:00
Timothy Gu
908f661664
2.0.0-alpha.1
...
Fixes #8 .
Fixes #209 .
Fixes #222 .
2017-01-14 21:36:08 -08:00
Timothy Gu
8cf1541fb0
Merge pull request #177 from bitinn/v2
...
node-fetch v2
2017-01-14 21:33:01 -08:00
Timothy Gu
502b604208
Fix Headers iterable initializer handling
2017-01-14 21:22:23 -08:00
Timothy Gu
f198f93767
test: remove fallbacks for Node.js 0.10
2017-01-14 20:56:26 -08:00
Timothy Gu
151de2bdfb
Use ES2015 export syntax ( #212 )
...
* Implement Rollup's external module check
* Use ES2015 export syntax
More friendly to ES2015 environments.
2017-01-14 20:50:10 -08:00
Timothy Gu
7970491000
Use template literals in Request
...
Closes #217 .
2016-12-14 15:45:00 -08:00
Nathan Rajlich
fa22529128
proper stack first line for FetchError instances ( #215 )
...
The `.stack` property gets cached in the `captureStackTrace()` call, so
whatever is set as the `name` and `message` at that time will be used
for the first line of the stack trace.
Before this patch, FetchError's stack would just say "Error" as the
first line. Now they correctly display the "${name}: ${message}" of the
error instances.
Test case included.
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
2016-12-14 15:41:35 -08:00