Skip to content

Releases: Automattic/fresh-data

Pre-release of underlying refactor

18 Jul 20:54
Compare
Choose a tag to compare
Pre-release

This is a pre-release of a pretty major refactor. Instead of tracking component requirements through their lifecycle, this release depends on the re-render of connected components to update requirements regularly. See #203 for details.

v0.5.0 pre-release - @wordpress/data compatibility

28 Nov 23:56
Compare
Choose a tag to compare

This release adds compatibility for @wordpress/data in the form of functions on the ApiClient class:

  • getSelectors( componentReqirements )
  • clearCompoentRequirements( component )
  • setCompoentRequirements( component, componentRequirements )

These functions allow roughly the same behavior as setComponentData before, but better integrates with the flow of @wordpress/data's select functionality.

0.4.0 release - Simplified api spec

22 Oct 22:16
Compare
Choose a tag to compare
Pre-release

This release simplifies the API spec given to fresh-data.

It removes the methods in favor of just pre-loading operations with the methods needed.

Additionally, this version changes the license from GPL v2.0+ to MIT for broader application usage.

0.2.0 Release - API updates

16 Jul 22:31
2706e7f
Compare
Choose a tag to compare
Pre-release

Changes affecting apis using fresh-data:

  1. Instead of ( getData, requireData ), selectors are now given
    ( getResource, requireResource ). Both of these functions return the
    state of the resource by its given key.
    a. getResource( resourceName ) returns resource state in the format
    of { data, error, lastReceived, lastRequested, lastError }. All
    properties of that state are optional and may not be present, but
    getResource will always return an object, even if it's empty.
    b. requireResource( requirement, resourceName ) sets a component
    requirement for the given resource, and then returns resource state in
    the same manner as getResource.

  2. mutations now return proper promises, which can be used to handle
    success and failure callbacks via a Promise resolve/reject, or by
    using async/await.

  3. Within the client class, methods, operations, mutations, and
    selectors are no longer static members, but members of the object
    instance. This provides greater flexibility in API implementation by
    allowing things such as passing methods in via a constructor.

Initial release

11 Jul 04:50
216408e
Compare
Choose a tag to compare
Initial release Pre-release
Pre-release

This is the initial release of the Fresh Data framework!