Skip to content

v6.0.0

Compare
Choose a tag to compare
@jstejada jstejada released this 16 Sep 15:34

Commits: v5.0.0...v6.0.0

Breaking

  • Environment no longer supports a configurable PublishQueue, this is a prerequisite for upcoming changes to support a new connection representation and the Store interface changes (see below): 44edf14
  • Changed the Store interface, adding snapshot() and restore() methods and changing the way that PublishQueue/Store coordinate to revert/rebase optimistic updates: a5c903d
    • Note: this should have no impact on users who use the default Store implementation; the main impact is to alternate store implementations and consumers thereof.
  • Removed the unused RecordSource interface load() method: bd15d4e
  • Changed dataFrom prop in ReactRelayQueryRenderer to fetchPolicy, changed 'STORE_THEN_NETWORK' to 'store-and-network'.
  • Changed $key in flow type for plural fragments to plural ($ReadOnlyArray<>)
  • environment.unstable_internal has been removed, since we no longer need to support Relay Compat.
  • Minimum required React version is now 16.9.0

Added

  • Added unreleased relay-experimental package which contains experimental version of Relay Hooks using React Suspense.
  • Added a LocalQueryRenderer that has the same API as QueryRenderer, and only renders from data in the store.
  • @inline directive and readInlineData() function that enables data masking for functions instead of React components.
  • Added an @raw_response_type directive on query, mutation and subscription. With the directive, a new flow type will be added to the generated artifact that represents the shape of the server response.
  • New documentation for Client Schema extensions and managing local data was added.

Improved

Fixed

  • Various fixes to the MockPayloadGenerator
    • Added test case for mocking null values (#2762 (#2762))
    • Fixed MockResolvers for Objects in plural fields
    • Fixed generated values for scalar arrays/enums
    • Fixed mock resolvers for arrays of Enums (#2779 (#2779))
    • Handle cases when MockResolver for ID returning undefined
  • Fix edge case in ConnectionHandler when field is unset
  • Fixed relay-compiler babel polyfill problem.
  • Use reporter to report changes (#2838)
  • Use global state for persisted queries to fix --watch (#2625 (#2625))

Misc

  • v6.0.0 should now be compatible with React 16.9.0.
  • Experimental: work-in-progress support for a new approach to representing connections, with changes starting in 6f01295. The new connection representation is not feature complete and disabled by a feature flag. The APIs are highly likely to change.
  • Added a new implementation of the RelayRecordsSource (available behind a feature flag)