Skip to content

Releases: badgateway/ketting

v6.0.0-alpha.3

07 Jul 00:13
cd1d92a
Compare
Choose a tag to compare
v6.0.0-alpha.3 Pre-release
Pre-release
  • Resources implement EventEmitter, and can emit stale, update and
    delete events.
  • The 'body' property on State is now 'data'
  • #141: Added head() function and ability to follow links just through HEAD
    methods via the Link header.
  • Added a NeverCache and ShortCache if automatically storing every State
    object until invalidation is not desired.
  • When calling put() with a new State object, that object will now be placed
    in cache.
  • When refreshing, fetch() is now given the 'reload' cache setting, so that
    refresh() is a true Refresh, even with a browser cache.
  • #130: Support relative bookmark URIs when using Ketting in a browser.
  • Siren was not correctly parsed.
  • Add .clone() method to all State object.

v6.0.0-alpha.2

07 Jul 00:13
98e864e
Compare
Choose a tag to compare
v6.0.0-alpha.2 Pre-release
Pre-release
  • State is now exported.
  • #184: Added a new postFollow() function that takes over the role of
    post(). post() is now intended for RPC-like operations and form
    submissions.

v6.0.0-alpha.1

07 Jul 00:13
ab54095
Compare
Choose a tag to compare
v6.0.0-alpha.1 Pre-release
Pre-release
  • Re-release. The build contained a few older files that weren't meant to be
    packaged.

v6.0.0-alpha.0

07 Jul 00:14
1afdb5a
Compare
Choose a tag to compare
v6.0.0-alpha.0 Pre-release
Pre-release
  • Big BC-breaking rewrite. Changes are numerous, but the important ones are
    listed here.
  • Resource.get() now returns a State object instead of just a response
    body. This object has methods to make it easier to manipulate and get
    information about the response, including links. It's also a stable,
    non-async object.
  • Ketting class is now called Client. It's still exposed as Ketting
    as well for BC purposes.
  • Client.getResource() has been removed. Use Client.go() instead.
  • A HTTP Fetch middleware system has been added, for easier manipulation of
    requests and responses. Middlewares can be added for every request, or
    for specific origins (domains).
  • All authentication settings have been removed, and reimplemented as
    fetch middlewares. They take roughly the same options, but the setup
    has changed.
  • Resource.get(), Resource.put(), etc. can now all take custom headers
    and other options to manipulate the request.
  • In the past you could just send a body with Resource.post(), .put(),
    .patch(). Now this body must be a wrapped in an object with at least a .body
    property. This is an annoying BC break but will allow for more flexibility
    that was previous impossible.
  • Proper support for 'binary' resources.
  • Hal Links will now be reserialized on put().
  • Resource.link, Resource.links and Resource.hasLink has been deprecated,
    but not removed.
  • Link objects are now a simple typescript type, and no longer implemented
    as a class.
  • FollowerOne is now FollowPromiseOne and FollowerMany is now
    FollowPromiseMany.
  • All things called Representor has been removed, and rewritten with
    a completely new API. A HAL representor is now a HalState.
  • #175: Nested embedded items are now also placed in the cache.

v5.2.1

03 Mar 23:33
fa1c8ac
Compare
Choose a tag to compare
  • Use the title= attribute from the HTTP Link header, if it exists.

v5.2.0

17 Feb 22:43
49e5a86
Compare
Choose a tag to compare
  • Added 'finally()' to custom follower promises.
  • All representors are now exported in the representor namespace.

v5.1.2

12 Feb 19:27
770ffa9
Compare
Choose a tag to compare
  • Correct return type on followAll, so it may be chained with preFetch.
    This was only an issue when doing 'multiple hops'.

v5.1.1

10 Jan 23:50
c9d8e2b
Compare
Choose a tag to compare
  • #173: De-duplicate HAL links if they appear in _embedded and _links.

v5.1.0

05 Jan 22:55
7e51da9
Compare
Choose a tag to compare
  • Support for the Collection+json format.
  • Added a preferTransclude() method on the Follower objects. This
    automatically adds a Prefer: tranclude="rel" header.

v5.0.1

18 Dec 19:32
5df5524
Compare
Choose a tag to compare
  • Update all dependencies.