Commit Graph

204 Commits

Author SHA1 Message Date
Timothy Gu 2cafdcb5e4 Validate headers 2016-10-15 08:21:51 -07:00
Timothy Gu fba873d3fe Make sure to coerce header values to string 2016-10-15 08:21:51 -07:00
Timothy Gu ba226399d4 Construct Headers object in a spec-compliant fashion 2016-10-15 08:21:51 -07:00
Timothy Gu 82c1e78184 Allow constructing Headers with an Array 2016-10-15 08:21:51 -07:00
Timothy Gu a914cca577 Remove all information related to Coveralls 2016-10-13 00:46:01 -07:00
Timothy Gu ba8c392965 Cache node_modules in Travis
[ci skip]
2016-10-13 00:42:26 -07:00
Timothy Gu b9b0341db7 Add Codecov badges and settings 2016-10-13 00:40:36 -07:00
Timothy Gu ea111626e9 Switch to Codecov
Fixes #186.
2016-10-13 00:32:52 -07:00
Timothy Gu 67326e3873 Condense class toString tests 2016-10-12 20:51:19 -07:00
Timothy Gu c2c6550e54 Use loose mode when compiling Babel 2016-10-12 18:18:37 -07:00
Timothy Gu 4d81cb4877 Test @@toStringTag getter of all classes 2016-10-12 17:29:33 -07:00
Timothy Gu 0f65af3fd8 Split Headers iterable test into four 2016-10-12 17:29:33 -07:00
Timothy Gu c3a121a360 Add support for Body#arrayBuffer 2016-10-12 17:29:33 -07:00
Timothy Gu 64e239b092 Improve Body spec compliance when body is null 2016-10-12 17:29:33 -07:00
Timothy Gu 9d3cc52601 Body: store fewer things in the class
Incorporates some changes from #140, by Gabriel Wicke
<gwicke@wikimedia.org>.
2016-10-12 17:29:33 -07:00
Timothy Gu a0be6aa34a Simplify Request constructor
Also make Request more standard compliant:

> The `url` attribute's getter must return request's url, **serialized.**
2016-10-12 17:29:33 -07:00
Timothy Gu 838071247d Convert all files to ES2015 (#182)
Elements of this commit come from #140 by @gwicke.
2016-10-10 11:50:04 -07:00
Timothy Gu 993d4cdea1 Convert Headers to ES2015 and implement Iterable interface (#180)
Closes #127, #174.
2016-10-08 20:51:01 -07:00
Timothy Gu 2874af4218 Use cross-env@2.0.1 to support Node.js < v4 2016-10-04 03:07:44 -07:00
Timothy Gu 7c26fa9479 Add Babel infrastructure
No actual code has been changed yet.
2016-10-04 02:59:46 -07:00
David Frank 3c053ce327 1.6.3 2016-09-26 14:16:41 +08:00
David Frank 2af4c00a67 be more open in form-data dependency 2016-09-26 14:16:32 +08:00
David Frank 0bc2886d10 Merge pull request #170 from bitinn/form-data-2
* testing both form-data 1.x and 2.x support
* a document for error handling
* changelog update
2016-09-26 14:08:11 +08:00
David Frank 2b9eadd989 changelog update 2016-09-26 14:03:28 +08:00
David Frank ff38361a9e a document for error handling 2016-09-26 14:03:00 +08:00
David Frank d4a225018f changelog update 2016-09-26 13:35:30 +08:00
David Frank 523a6920aa testing both form-data 1.x and 2.x support 2016-09-26 12:58:04 +08:00
David Frank b2e6cca648 1.6.2 2016-09-24 17:53:11 +08:00
David Frank 813cb479a6 changelog update 2016-09-24 17:53:04 +08:00
David Frank 43e06ca422 add catch example to readme 2016-09-24 17:21:40 +08:00
David Frank e926483448 minor format fix and comments 2016-09-24 17:12:18 +08:00
Dan Dascalescu 95b58936b8 Return empty .json() object on 204. Fix #165. (#166)
Handle an edge case where 204 No Content response body is empty, but node-fetch trying to parse the empty body as-is.
2016-09-24 17:06:18 +08:00
David Frank 3e53f0c2c8 1.6.1 2016-09-11 23:37:00 +08:00
David Frank ffddec0ad2 fix test: buffer.alloc is not available for older node.js release 2016-09-11 23:34:50 +08:00
David Frank 788c4627a7 make sure we default to 200 on new response 2016-09-11 23:17:09 +08:00
David Frank 6a0dd463b0 update limit document 2016-09-11 23:08:11 +08:00
David Frank bdd80e45fd changelog update 2016-09-11 22:37:42 +08:00
David Frank f17aa9af1f call tostring on plain object body 2016-09-11 22:33:22 +08:00
David Frank e4a7da8326 making sure headers will drop buffer value 2016-09-11 22:18:43 +08:00
David Frank 515525a388 update limit document on cookie headers 2016-09-11 22:13:00 +08:00
David Frank 067ea8190a changelog update 2016-09-11 22:05:32 +08:00
David Frank 6bac50f1da fix bug related to request wrapping, where counter adopts follow value incorrectly 2016-09-11 22:02:39 +08:00
David Frank e574b497d5 make sure example is working 2016-08-16 20:22:18 +08:00
David Frank 8fc30a8d8c Merge pull request #148 from jimmywarting/patch-2
update readme with binary file/buffer examples
2016-08-16 19:27:37 +08:00
Jimmy Karl Roland Wärting d8c6969736 added 2 binary exemple
Got to many "how do i handle binary/images" issues
2016-08-16 11:40:31 +02:00
David Frank 4e455a4185 1.6.0 2016-08-03 18:08:24 +08:00
David Frank ed9a72d84e Merge pull request #141 from bitinn/august-bugfix
August bugfix, see commit for details
2016-08-03 18:07:51 +08:00
David Frank 8cce714b48 changelog and documentation update 2016-08-03 18:02:26 +08:00
David Frank d24ec6f7c4 handle raw deflate response from old servers 2016-08-03 17:31:46 +08:00
David Frank c82e4dad13 mark non-spec api 2016-08-03 14:05:59 +08:00