Releases: sindresorhus/ky
Releases · sindresorhus/ky
v0.16.1
v0.16.0
Breaking
- Hooks now always receive a
Request
instance as the first argument instead of the input URL, which could previously either be astring
,Request
, orURL
(#180) c5821a7
Enhancements
- Pass all Ky options to hooks (#188) a5c249e
- Allow overriding the default accept headers (#200) 65f38f9
- Add ability to stop retries in
beforeRetry
hooks (#198) 0bc6fb1 beforeRequest
hooks can now return aRequest
instance to replace the existing request (#180)
Fixes
- Avoid body method parse errors on 204 responses (#196) a1c000e
- Fix global property lookup (#203) c0d9d2b
Docs
- Document
prefixUrl
reasonings (#175) 4e05289 - Improve example in documentation for using umd.js (#190) 3b87b93
Meta
v0.15.0
v0.14.0
v0.13.0
Breaking
await ky('…', {
hooks: {
beforeRequest: [
- options => {}
+ (input, options) => {}
]
afterResponse: [
- response => {}
+ (input, options, response) => {}
]
}
});
Enhancements
- Make the
retry
option more powerful (#110) d4ddb7a
You can now control which HTTP methods and status codes that should cause a retry. - Simplify the
Options
TypeScript type (#165) bfdc9b5
This should make it easier to wrap Ky when using TypeScript.
v0.12.0
v0.11.2
v0.11.1
- Fix TypeScript 3.5 compatibility 93d2faf
v0.11.0
v0.10.0
Breaking (for TypeScript users only):
- Don't export the
Ky
TypeScript namespace 7114ba3
Enhancements:
- Set accept header for Ky shortcut methods (#118) afc18ea
- Make it possible to install Ky in Node.js 8 even though it's not support (This is to re-enable Node.js 8 support in
ky-universal
) fcffa18
Fixes: