1 | ChangeLog
|
2 | =========
|
3 |
|
4 | 6.0.4 (2020-10-04)
|
5 | ------------------
|
6 |
|
7 | * State objects now have an `actions()` method that return all defined
|
8 | actions.
|
9 |
|
10 |
|
11 | 6.0.3 (2020-09-30)
|
12 | ------------------
|
13 |
|
14 | * #241: Add `application/prs.hal-forms+json` to Accept header and treat as
|
15 | HAL (@reda-alaoui).
|
16 | * #260: `action()` could not be successfully called on a HAL action.
|
17 | (@reda-alaoui).
|
18 | * Add `action()` function to `State` interface.
|
19 |
|
20 |
|
21 | 6.0.2 (2020-09-28)
|
22 | ------------------
|
23 |
|
24 | * #248: Parse JSON objects that have an array at the top-level.
|
25 | * #257: `ETag` and `Last-Modified` are now treated as 'Content headers', which
|
26 | means they will get returned from `getContentHeaders()`.
|
27 |
|
28 |
|
29 | 6.0.1 (2020-09-09)
|
30 | ------------------
|
31 |
|
32 | * Quick re-release. Some files were left in the `dist/` directory that were
|
33 | not cleaned up.
|
34 |
|
35 |
|
36 | 6.0.0 (2020-09-09)
|
37 | ------------------
|
38 |
|
39 | * New major release!
|
40 | * Added support for [Siren][1] action fields.
|
41 | * Added support for [HAL Forms][4].
|
42 |
|
43 |
|
44 | 6.0.0-beta.2 (2020-08-15)
|
45 | -------------------------
|
46 |
|
47 | * Support `draft-nottingham-link-hint` on Links.
|
48 | * Added: `client.fetcher.advertiseKetting`. Setting this to false will cause
|
49 | Ketting to *not* set the `User-Agent` header.
|
50 | * `Resource.patch()` will now return a `State `object if the server responded
|
51 | with `200 OK` and a body.
|
52 |
|
53 |
|
54 | 6.0.0-beta.1 (2020-08-10)
|
55 | -------------------------
|
56 |
|
57 | * #229: Embedded resources were not cached. (@madsmadsen)
|
58 | * #230: Respect `headers` property in options of `refresh()` function.
|
59 | (@madsmadsen)
|
60 | * Lots of Ketting 6 doc updates.
|
61 | * JSDocs everywhere gotten a fresh proof read.
|
62 |
|
63 |
|
64 | 6.0.0-beta.0 (2020-07-06)
|
65 | -------------------------
|
66 |
|
67 | * Switched from tslint to eslint.
|
68 | * Feature complete!
|
69 |
|
70 |
|
71 | 6.0.0-alpha.7 (2020-06-19)
|
72 | --------------------------
|
73 |
|
74 | * `isState()` type guard is exported.
|
75 |
|
76 |
|
77 | 6.0.0-alpha.6 (2020-06-16)
|
78 | --------------------------
|
79 |
|
80 | * The Links object now has a default 'context', making it easier to add
|
81 | relative links.
|
82 | * Links now has an easier to use API for setting or adding new links.
|
83 | * Links now has a `.delete()` method to delete by `rel`.
|
84 |
|
85 |
|
86 | 6.0.0-alpha.5 (2020-06-08)
|
87 | --------------------------
|
88 |
|
89 | * Added 'actions', allowing users to automatically submit actions and/or Forms
|
90 | for supported formats.
|
91 | * Action support is added for `text/html` and `application/vnd.siren+json`
|
92 | * Supported content-types for actions are `application/json` and
|
93 | `application/x-www-form-urlencoded`.
|
94 | * `State` objects now have a reference to `Client`.
|
95 | * `resolve()` function is now a package export, providing a cross-platform
|
96 | function for resolving urls.
|
97 | * `Resource` has now a `updateCache` function for local state changes without
|
98 | submitting to the server.
|
99 | * `refresh()` now emits an `update` event.
|
100 |
|
101 |
|
102 | 6.0.0-alpha.4 (2020-05-11)
|
103 | --------------------------
|
104 |
|
105 | * Fixing bugs related to `patch()`, `post()` in the browser build.
|
106 |
|
107 |
|
108 | 6.0.0-alpha.3 (2020-05-10)
|
109 | --------------------------
|
110 |
|
111 | * `Resources` implement EventEmitter, and can emit `stale`, `update` and
|
112 | `delete` events.
|
113 | * The 'body' property on State is now 'data'
|
114 | * #141: Added `head()` function and ability to follow links just through `HEAD`
|
115 | methods via the `Link` header.
|
116 | * Added a `NeverCache` and `ShortCache` if automatically storing every `State`
|
117 | object until invalidation is not desired.
|
118 | * When calling `put()` with a new `State` object, that object will now be placed
|
119 | in cache.
|
120 | * When refreshing, `fetch()` is now given the 'reload' cache setting, so that
|
121 | `refresh()` is a true Refresh, even with a browser cache.
|
122 | * #130: Support relative bookmark URIs when using Ketting in a browser.
|
123 | * Siren was not correctly parsed.
|
124 | * Add `.clone()` method to all `State` object.
|
125 |
|
126 |
|
127 |
|
128 | 6.0.0-alpha.2 (2020-05-03)
|
129 | --------------------------
|
130 |
|
131 | * `State` is now exported.
|
132 | * #184: Added a new `postFollow()` function that takes over the role of
|
133 | `post()`. `post()` is now intended for RPC-like operations and form
|
134 | submissions.
|
135 |
|
136 |
|
137 | 6.0.0-alpha.1 (2020-05-03)
|
138 | --------------------------
|
139 |
|
140 | * Re-release. The build contained a few older files that weren't meant to be
|
141 | packaged.
|
142 |
|
143 |
|
144 | 6.0.0-alpha.0 (2020-04-28)
|
145 | --------------------------
|
146 |
|
147 | * Big BC-breaking rewrite. Changes are numerous, but the important ones are
|
148 | listed here.
|
149 | * `Resource.get()` now returns a `State` object instead of just a response
|
150 | body. This object has methods to make it easier to manipulate and get
|
151 | information about the response, including links. It's also a stable,
|
152 | non-async object.
|
153 | * `Ketting` class is now called `Client`. It's still exposed as `Ketting`
|
154 | as well for BC purposes.
|
155 | * `Client.getResource()` has been removed. Use `Client.go()` instead.
|
156 | * A HTTP Fetch middleware system has been added, for easier manipulation of
|
157 | requests and responses. Middlewares can be added for every request, or
|
158 | for specific origins (domains).
|
159 | * All authentication settings have been removed, and reimplemented as
|
160 | fetch middlewares. They take roughly the same options, but the setup
|
161 | has changed.
|
162 | * `Resource.get()`, `Resource.put()`, etc. can now all take custom headers
|
163 | and other options to manipulate the request.
|
164 | * In the past you could just send a body with `Resource.post()`, `.put()`,
|
165 | .`patch()`. Now this body must be a wrapped in an object with at least a `.body`
|
166 | property. This is an annoying BC break but will allow for more flexibility
|
167 | that was previous impossible.
|
168 | * Proper support for 'binary' resources.
|
169 | * Hal Links will now be reserialized on `put()`.
|
170 | * `Resource.link`, `Resource.links` and `Resource.hasLink` has been deprecated,
|
171 | but not removed.
|
172 | * `Link` objects are now a simple typescript type, and no longer implemented
|
173 | as a class.
|
174 | * `FollowerOne` is now `FollowPromiseOne` and `FollowerMany` is now
|
175 | `FollowPromiseMany`.
|
176 | * All things called `Representor` has been removed, and rewritten with
|
177 | a completely new API. A `HAL representor` is now a `HalState`.
|
178 | * #175: Nested embedded items are now also placed in the cache.
|
179 |
|
180 |
|
181 | 5.2.1 (2020-03-03)
|
182 | ------------------
|
183 |
|
184 | * Use the `title=` attribute from the HTTP Link header, if it exists.
|
185 |
|
186 | 5.2.0 (2020-02-17)
|
187 | ------------------
|
188 |
|
189 | * Added 'finally()' to custom follower promises.
|
190 | * All representors are now exported in the `representor` namespace.
|
191 |
|
192 |
|
193 | 5.1.2 (2020-02-12)
|
194 | ------------------
|
195 |
|
196 | * Correct return type on followAll, so it may be chained with preFetch.
|
197 | This was only an issue when doing 'multiple hops'.
|
198 |
|
199 |
|
200 | 5.1.1 (2020-01-10)
|
201 | ------------------
|
202 |
|
203 | * #173: De-duplicate HAL links if they appear in _embedded and _links.
|
204 |
|
205 |
|
206 | 5.1.0 (2020-01-05)
|
207 | ------------------
|
208 |
|
209 | * Support for the [Collection+json][4] format.
|
210 | * Added a `preferTransclude()` method on the Follower objects. This
|
211 | automatically adds a `Prefer: tranclude="rel"` header.
|
212 |
|
213 |
|
214 | 5.0.1 (2019-12-09)
|
215 | ------------------
|
216 |
|
217 | * Update all dependencies.
|
218 |
|
219 |
|
220 | 5.0.0 (2019-11-22)
|
221 | ------------------
|
222 |
|
223 | * This version is the exact same as the previous alpha.
|
224 |
|
225 |
|
226 | 5.0.0-alpha.7 (2019-11-12)
|
227 | --------------------------
|
228 |
|
229 | * Added `hasLink` on Resources and Representations.
|
230 |
|
231 |
|
232 | 5.0.0-alpha.6 (2019-11-06)
|
233 | --------------------------
|
234 |
|
235 | * Fixed a bug in `getOptions()`
|
236 |
|
237 |
|
238 | 5.0.0-alpha.5 (2019-11-06)
|
239 | --------------------------
|
240 |
|
241 | * Added a `preferPush()` method to 'Follower' objects, allowing you to
|
242 | automatically send [`Prefer-Push`][3] headers when following links.
|
243 | * Moved all functionality related to the 'Repreprentor' in a utility class,
|
244 | making both the `Ketting` and `Resource` classes simpler.
|
245 | * Simplified `Resource.refresh()`, making it easier to read and do less work.
|
246 | * When calling `.post()`, the function will only return a new resource if the
|
247 | HTTP response code was `201`.
|
248 | * If the HTTP response code to a `post()` call was `205`, it will now return
|
249 | the current resource.
|
250 | * Removed the logic for automatically adding `Prefer-Push` headers. This was
|
251 | unreliable, and usually did the wrong thing. The new system is 100% opt-in
|
252 | and developer-driven.
|
253 | * Added `Ketting.getOptions()` to return a list of options that were passed to
|
254 | Ketting. The options will be enhanced with OAuth2 refresh and access tokens
|
255 | as they become available, meaning that it can be used to place in
|
256 | LocalStorage to remember sessions. This feature is experimental and
|
257 | incomplete. It might change even in minor versions.
|
258 |
|
259 |
|
260 | 5.0.0-alpha.4 (2019-10-31)
|
261 | --------------------------
|
262 |
|
263 | * This version is identical to the last, but fixes an issue on npmjs.com.
|
264 | Updating is not needed.
|
265 |
|
266 |
|
267 | 5.0.0-alpha.3 (2019-10-31)
|
268 | --------------------------
|
269 |
|
270 | * It's now possible to tell Ketting to prefetch every resource when following
|
271 | links via `Resource.follow('foo').preFetch()`.
|
272 | * `Link` and `LinkNotFound` are now both exported.
|
273 | * Documentation overhaul.
|
274 |
|
275 |
|
276 | 5.0.0-alpha.2 (2019-10-21)
|
277 | --------------------------
|
278 |
|
279 | * Slight tweak to the webpack build, so that other typescript + webpack
|
280 | projects can use the webpack build and use the minified files.
|
281 |
|
282 |
|
283 | 5.0.0-alpha.1 (2019-10-21)
|
284 | --------------------------
|
285 |
|
286 | * Now supports the 'invalidates' link rel. When specified in a HTTP response,
|
287 | Ketting will automatically clear the cache of any related resources.
|
288 | See [draft-nottingham-linked-cache-inv-04][2].
|
289 |
|
290 |
|
291 | 5.0.0-alpha.0 (2019-10-18)
|
292 | --------------------------
|
293 |
|
294 | * Support for the [Siren][1] format.
|
295 | * Rewrite of the 'representation' system, which is responsible for supporting
|
296 | all the different media types. This results in a few small BC breaks.
|
297 | * NEW: `follow()` and `followAll()` now throw `LinkNotFound` instead of the
|
298 | generic `Error` when a link could not be found.
|
299 | * NEW: Resources now have a `link(rel: string)` function, which returns a
|
300 | a single `Link` object.
|
301 | * BC BREAK: `Ketting.getRepresentor()` is now `Ketting.createRepresentation()`
|
302 | and is responsible for constructing the object instead of just returning a
|
303 | constructor.
|
304 | * BC Break: `body`, `links` and `embedded` on `Representor` objects are all
|
305 | gone and replaced with `getBody()`, `getLinks()` and `getEmbedded()`.
|
306 | * BUG: Hal is now more lenient with broken responses.
|
307 | * NEW: Compatible with Typescript's `strictNullChecks` setting. Overall
|
308 | stronger typing all around.
|
309 | * NEW: Hal responses from the HAL representor are now properly typed.
|
310 | * CHANGE: Link chaining system has been rewritten, opening the door to new
|
311 | features that weren't possible before.
|
312 |
|
313 | 4.0.4 (2019-10-31)
|
314 | ------------------
|
315 |
|
316 | * This version is identical to the last, but fixes an issue on npmjs.com.
|
317 | Updating is not needed.
|
318 |
|
319 |
|
320 | 4.0.3 (2019-09-11)
|
321 | ------------------
|
322 |
|
323 | * The internal resource cache will now evict items for any non-safe HTTP
|
324 | method.
|
325 |
|
326 |
|
327 | 4.0.2 (2019-09-05)
|
328 | ------------------
|
329 |
|
330 | * Broke Typescript exports again
|
331 |
|
332 |
|
333 | 4.0.1 (2019-09-05)
|
334 | ------------------
|
335 |
|
336 | * Fix Typescript defintion files so Ketting may be imported correctly.
|
337 |
|
338 |
|
339 | 4.0.0 (2019-09-04)
|
340 | ------------------
|
341 |
|
342 | * #129: Using the package in non-typescript node.js now works with a simple
|
343 | `const Ketting = require('ketting')`.
|
344 | * #129: Fixed the browser distribution. the `Ketting` constructor is
|
345 | registered globally again.
|
346 |
|
347 |
|
348 | 4.0.0-alpha.0 (2019-04-22)
|
349 | --------------------------
|
350 |
|
351 | * The old format for OAuth2 setup is now no longer supported.
|
352 | * It's now possible to specify per-domain authentication using wildcards.
|
353 | This allows you to set up specific authentication credentials for specific
|
354 | domains. This might be useful in case you talk to multiple API's with a
|
355 | single client.
|
356 |
|
357 |
|
358 | 3.1.0 (2019-03-28)
|
359 | ------------------
|
360 |
|
361 | * If Ketting anticipates that a user might want to fetch multiple resources
|
362 | in sequence (a follow chain), it will now add `Prefer-Push` header and
|
363 | a `Prefer: transclude` header. Both are experimental internet drafts to
|
364 | suggest to a server to do a HTTP/2 push or embed a child resource
|
365 | respecitvely. This feature is experimental and might change as these drafts
|
366 | change.
|
367 |
|
368 |
|
369 | 3.0.2 (2019-03-19)
|
370 | ------------------
|
371 |
|
372 | * A mistake was made when releasing version 3. A branched was not merged in
|
373 | entirely, which caused some of the new OAuth2 features to be partially
|
374 | missing. This has now been corrected.
|
375 |
|
376 |
|
377 | 3.0.1 (2019-03-18)
|
378 | ------------------
|
379 |
|
380 | * Updated dependencies
|
381 |
|
382 | 3.0.0 (2019-03-18)
|
383 | ------------------
|
384 |
|
385 | * Switched OAuth2 implementation from `client-oauth2` to `fetch-mw-oauth2`.
|
386 | This adds support for `authorization_code` auth, removes 11 dependencies and
|
387 | reduces the minified Ketting build from 69KB to 28KB.
|
388 | * OAuth2 options now have a new format. The old format is still supported, but
|
389 | will be removed from a future version.
|
390 | * The `baseHref` propertyname was renamed to `Context` on the `Link` type. The
|
391 | new name matches the name from RFC8288. This is a small BC break.
|
392 |
|
393 |
|
394 | 2.5.1 (2019-03-01)
|
395 | ------------------
|
396 |
|
397 | * #120: The system that de-duplicates identical requests will cache failures
|
398 | forever. This is now fixed. Highly recommended update.
|
399 |
|
400 |
|
401 | 2.5.0 (2019-01-22)
|
402 | ------------------
|
403 |
|
404 | * Basic JSON:API support. Currently only links appearing in the top-level
|
405 | document are supported.
|
406 | * #113: Support for Typescript environments that don't have `esModuleInterop`
|
407 | set to true.
|
408 | * Added a 'go' function for easily getting resources based on relative uris.
|
409 |
|
410 |
|
411 | 2.4.1 (2018-11-07)
|
412 | ------------------
|
413 |
|
414 | * If a link appears in both `_embedded` and `_links`, they will be
|
415 | de-duplicated. HAL technically requires links to appear in both places, so
|
416 | scanning `_embedded` should not be needed. However, most implementations will
|
417 | not add links `_links` if they were already `_embedded`. This change caters
|
418 | both usages.
|
419 |
|
420 |
|
421 | 2.4.0 (2018-11-05)
|
422 | ------------------
|
423 |
|
424 | * The `Resource` class is now a generic typescript type. This allows a user
|
425 | of the library to define specific 'types of resources' and leverage static
|
426 | typing for `GET` and `PUT` requests.
|
427 | * A few documentation updates.
|
428 |
|
429 |
|
430 | 2.3.0 (2018-10-10)
|
431 | ------------------
|
432 |
|
433 | * Better handling of `Content-Types`. When following HAL links that have a
|
434 | `type` parameter, the type is rememebered and used in `Accept` and
|
435 | `Content-Type` headers, for `GET`, `PUT` and `POST` requests.
|
436 | * If no `type` was provided, it will use the last `Content-Type` header from
|
437 | `GET` response.
|
438 | * If that `GET` request never happened, it uses the first 'default'
|
439 | `Content-Type` from client.contentTypes, and enumerates all mime-types from
|
440 | that list for `Accept` headers.
|
441 | * No longer incorrectly sends `text/plain` Content-Types.
|
442 | * Optimization: If multiple calls are made to ask for a Resource's current
|
443 | representation, all these calls are coalesced into one. The big benefit is
|
444 | that there are no longer multiple parallel `GET` requests.
|
445 | * Webpack browser build is set to 'production' mode.
|
446 | * Fixed: After refreshing an OAuth2 token, the new access token wasn't used.
|
447 |
|
448 |
|
449 | 2.2.1 (2018-09-19)
|
450 | ------------------
|
451 |
|
452 | * Refreshing OAuth2 tokens without having a refresh_token.
|
453 | `client_credentials` in particular shouldn't return a `refresh_token`, so
|
454 | for these cases, new access tokens are acquired using a new
|
455 | `client_credentials` request.
|
456 |
|
457 |
|
458 | 2.2.0 (2018-09-18)
|
459 | ------------------
|
460 |
|
461 | * Support for OAuth2 `client_credentials` grant.
|
462 |
|
463 |
|
464 | 2.1.0 (2018-09-14)
|
465 | ------------------
|
466 |
|
467 | * No longer ships with `cross-fetch` and `whatwg-fetch`. To use this library
|
468 | in a browser, you must run this in a browser that supports `fetch` or
|
469 | provide your own polyfill.
|
470 | * Updated dependencies
|
471 |
|
472 |
|
473 | 2.0.4 (2018-09-12)
|
474 | ------------------
|
475 |
|
476 | * Fixed bug: HAL title values weren't parsed.
|
477 |
|
478 |
|
479 | 2.0.3 (2018-08-23)
|
480 | ------------------
|
481 |
|
482 | * Exporting 'Resource' for TS purposes.
|
483 |
|
484 |
|
485 | 2.0.2 (2018-08-23)
|
486 | ------------------
|
487 |
|
488 | * Updated dependencies
|
489 | * Fixed a typescript definition problem.
|
490 |
|
491 |
|
492 | 2.0.1 (2018-06-17)
|
493 | ------------------
|
494 |
|
495 | * Same as last build.
|
496 |
|
497 | 2.0.0 (2018-06-17)
|
498 | ------------------
|
499 |
|
500 | * #71: Total conversion to Typescript.
|
501 | * BC break: Minified files are now in the `browser/` directory, not the `dist/`
|
502 | directory.
|
503 | * #78: Webpack build had a broken version of `querystring`, which caused
|
504 | `Link:` header parsing to fail in browsers.
|
505 | * #80: `resource.fetch()` would throw an exception with some combinations
|
506 | of arguments.
|
507 | * #90: `get()` and `refresh()` will now throw an Error when a server did not
|
508 | include a content-type.
|
509 | * #89: Refactored OAuth utility to be a bit more clear.
|
510 | * #83: Support for `resource.patch()`. The implementation is pretty basic. Let
|
511 | us know how you would like to use it!
|
512 |
|
513 |
|
514 | 1.1.0 (2018-04-07)
|
515 | ------------------
|
516 |
|
517 | * #70: Moved all source from `lib/` to `src/`. This is prepping for typescript
|
518 | support.
|
519 | * #73: Mocha tests can now be ran in a browser.
|
520 | * #76: Fixed a browser bug: Headers is not a constructor.
|
521 |
|
522 |
|
523 | 1.0.0 (2018-03-25)
|
524 | ------------------
|
525 |
|
526 | * #66: Support for Accept header weighing with the q= parameter.
|
527 | * #68: Updated all dependencies to their latest version.
|
528 |
|
529 |
|
530 | 0.10.3 (2018-01-31)
|
531 | -------------------
|
532 |
|
533 | * #63: It was not possible to expand templated links with variables after more
|
534 | than one chained hop. (@mhum).
|
535 |
|
536 |
|
537 | 0.10.2 (2018-01-31)
|
538 | -------------------
|
539 |
|
540 | * #62: It was not possible to override headers such as `Content-Type` when
|
541 | calling `Resource.fetch()`, if these were also set in the `fetchInit`
|
542 | defaults. (@mhum).
|
543 |
|
544 |
|
545 | 0.10.1 (2018-01-31)
|
546 | -------------------
|
547 |
|
548 | * #60: Chaining more than 2 `follow` statements did not work.
|
549 |
|
550 |
|
551 | 0.10.0 (2017-11-16)
|
552 | -------------------
|
553 |
|
554 | * #19: Support for OAuth2 access and refresh tokens. When used, the library
|
555 | can automatically refresh the access token if the previous one expired. It
|
556 | can also supports the `client_credentials` OAuth2 grant (@mhum).
|
557 |
|
558 |
|
559 | 0.9.0 (2017-09-23)
|
560 | ------------------
|
561 |
|
562 | * #52: Now using the new URL object in browsers for resolving relative urls,
|
563 | and falling back to a DOM based url resolving mechanism if it's not
|
564 | available. This causes the browser distribution to drop another 10KB to
|
565 | 46KB.
|
566 | * Moved a bunch of utility objects into a `util/` directory, so it's more
|
567 | clear what the important API's are.
|
568 | * #55: Fixed another problem related to the fetchInit function in firefox.
|
569 |
|
570 |
|
571 | 0.8.3 (2017-09-10)
|
572 | -----------------
|
573 |
|
574 | * Including the sourcemap file in the NPM distribution.
|
575 |
|
576 |
|
577 | 0.8.2 (2017-09-10)
|
578 | -----------------
|
579 |
|
580 | * #53: Regression related to the new 'fetchInit' option.
|
581 | * Now generating source maps.
|
582 |
|
583 |
|
584 | 0.8.1 (2017-09-04)
|
585 | ------------------
|
586 |
|
587 | * #50: Allow Fetch settings to be passed to the constructor of Ketting, so that
|
588 | settings such as `credentials: include` may be passed.
|
589 |
|
590 |
|
591 | 0.8.0 (2017-08-28)
|
592 | ------------------
|
593 |
|
594 | * #49: Removed support for expanding CURIEs in HAL. This was in conflict with
|
595 | the HAL standard. The canonical relation type is the prefix in the REL, not
|
596 | the expanded CURIE uri.
|
597 |
|
598 |
|
599 | 0.7.1 (2017-08-24)
|
600 | ------------------
|
601 |
|
602 | * Lots of documentation updates.
|
603 | * Including web distribution in NPM package.
|
604 |
|
605 |
|
606 | 0.7.0 (2017-08-21)
|
607 | ------------------
|
608 |
|
609 | * This library is now called Ketting. It used to be called Restl. Ketting is
|
610 | the dutch word for chain.
|
611 | * Automatically expanding Curies in the HAL `_link` object.
|
612 |
|
613 |
|
614 | 0.6.0 (2017-08-20)
|
615 | ------------------
|
616 |
|
617 | * #15: Browser support via webpack!
|
618 | * #45: Removed Bluebird dependency.
|
619 | * #16: Parsing the HTTP `Link` header (RFC5988).
|
620 | * #30: Added support for automatically parsing `application/problem+json` error
|
621 | responses and throwing better exceptions. (RFC7807).
|
622 | * #47: Link object now uses an object as its only constructor argument.
|
623 |
|
624 |
|
625 | 0.5.0 (2017-08-08)
|
626 | ------------------
|
627 |
|
628 | * #41: Support for parsing HTML5. The library can now extract `link` and `a`
|
629 | elements with `rel` attributes.
|
630 | * Removed the `accept` option. This should now be controlled with the
|
631 | `contentTypes` property.
|
632 | * #40: Removed support for the Requests library. This library now only used
|
633 | the Fetch API, to make it compatible with browsers in the future.
|
634 |
|
635 |
|
636 | 0.4.2 (2017-08-03)
|
637 | ------------------
|
638 |
|
639 | * #39: Making it easier to fire off custom HTTP requests on a resource using
|
640 | the Fetch API. You can now just provide the `init` argument without providing
|
641 | a url.
|
642 |
|
643 |
|
644 | 0.4.1 (2017-07-07)
|
645 | ------------------
|
646 |
|
647 | * #38: Add HTTP response to HTTP-related exceptions.
|
648 |
|
649 |
|
650 | 0.4.0 (2017-07-07)
|
651 | ------------------
|
652 |
|
653 | * #37: Support for templated uris.
|
654 |
|
655 |
|
656 | 0.3.2 (2017-04-27)
|
657 | ------------------
|
658 |
|
659 | * #33: Support for OAuth2 Bearer token.
|
660 |
|
661 |
|
662 | 0.3.1 (2017-04-26)
|
663 | ------------------
|
664 |
|
665 | * #31: Support for setting a standard `Content-Type` HTTP header.
|
666 |
|
667 |
|
668 | 0.3.0 (2017-04-24)
|
669 | ------------------
|
670 |
|
671 | * #28: Support for Basic Authentication
|
672 |
|
673 |
|
674 | 0.2.1 (2017-04-21)
|
675 | ------------------
|
676 |
|
677 | * #27: Fixed exception messages, they missed the HTTP status code.
|
678 |
|
679 |
|
680 | 0.2.0 (2017-04-21)
|
681 | ------------------
|
682 |
|
683 | * #17: Now using the Fetch API instead of the requests library. The requests
|
684 | library is kept around for BC purposes, but this will eventually be removed.
|
685 | * #25: the resourceCache was accidentally shared between Client instances.
|
686 |
|
687 |
|
688 | 0.1.2 (2017-04-19)
|
689 | ------------------
|
690 |
|
691 | * #11: Added test framework.
|
692 | * #11: Added `follow()` function on Client object for an easy shortcut.
|
693 |
|
694 |
|
695 | 0.1.1 (2017-04-03)
|
696 | ------------------
|
697 |
|
698 | * #10: Returning the response body from the `refresh()` function, similar to
|
699 | `GET` but cache-defeating.
|
700 |
|
701 |
|
702 | 0.1.0 (2017-02-13)
|
703 | ------------------
|
704 |
|
705 | * #7: Strip `_embedded` and `_links` from `Representation.body`. They are
|
706 | already available through `Representation.embedded` and
|
707 | `Representation.links`.
|
708 | * Added a cache for resources in the Client object, which ensures that if you
|
709 | request the same resource twice, you'll end up with the same object.
|
710 | * #6: Automatically parse `_embedded` and treat items in this object as real
|
711 | resources.
|
712 | * Fixed a bug in `post()`.
|
713 | * Allowing custom headers to be set, and allowing default headers to be
|
714 | overridden.
|
715 | * Automatically resolve all urls from `links()`.
|
716 |
|
717 |
|
718 | 0.0.4 (2017-02-06)
|
719 | -----------------
|
720 |
|
721 | * Bugfixes.
|
722 | * Linting with eslint.
|
723 |
|
724 |
|
725 | 0.0.3 (2017-02-06)
|
726 | ------------------
|
727 |
|
728 | * Now using Bluebird for promises, so we can extend them.
|
729 | * #2: Custom requests are now possible on `Resource` objects.
|
730 | * #3: Promises returned from `follow()` now have a `follow()` function
|
731 | themselves, making it extremely easy to hop from link to link.
|
732 | * Added a `post()` method for making new resources. This function returns a
|
733 | `Resource` object again if the response contained a `Location` header.
|
734 | * #4: Things in the `_embedded` property are now also treated as links and can
|
735 | be followed.
|
736 | * The `links()` method on Resource now have a `rel` argument for easy filtering.
|
737 | * Added a `followAll()` function for getting collections.
|
738 |
|
739 |
|
740 | 0.0.2 (2017-01-03)
|
741 | ------------------
|
742 |
|
743 | * `PUT` request.
|
744 | * `DELETE` request.
|
745 |
|
746 |
|
747 | 0.0.1 (2016-12-28)
|
748 | ------------------
|
749 |
|
750 | * First version!
|
751 | * Parses HAL `_links`.
|
752 | * Follows links.
|
753 | * `GET` requests.
|
754 | * `refresh()` function.
|
755 |
|
756 | [1]: https://github.com/kevinswiber/siren
|
757 | [2]: https://tools.ietf.org/html/draft-nottingham-linked-cache-inv-04
|
758 | [3]: https://tools.ietf.org/html/draft-pot-prefer-push
|
759 | [4]: http://amundsen.com/media-types/collection/format/
|
760 | [5]: http://rwcbook.github.io/hal-forms/
|