Skip to content

Releases: relay-tools/react-relay-network-modern

v2.3.4

13 Sep 06:38
Compare
Choose a tag to compare

2.3.4 (2018-09-13)

Bug Fixes

  • cacheMiddleware: do not cache responses with errors by default (#35) (c16e42d)

v2.3.3

06 Jun 10:11
Compare
Choose a tag to compare

2.3.3 (2018-06-06)

Bug Fixes

  • change relay-runtime to react-relay package in peerDependencies (331a2f7)

v2.3.2

05 Jun 10:28
Compare
Choose a tag to compare

2.3.2 (2018-06-05)

Bug Fixes

  • mjs build for old browsers (5733f10)

v2.3.1

23 May 09:56
Compare
Choose a tag to compare

2.3.1 (2018-05-23)

Bug Fixes

  • move repo to relay-tools organization (23cb244)

v2.3.0

21 May 09:47
Compare
Choose a tag to compare

2.3.0 (2018-05-21)

Features

  • add mjs build (es6 modules) for tree shaking (f668f10)

v2.2.0

18 May 02:39
Compare
Choose a tag to compare

2.2.0 (2018-05-18)

Features

v2.1.2

11 Apr 15:17
Compare
Choose a tag to compare

2.1.2 (2018-04-11)

Bug Fixes

v2.1.1

27 Mar 19:42
Compare
Choose a tag to compare

2.1.1 (2018-03-27)

Bug Fixes

v2.1.0

15 Mar 14:27
Compare
Choose a tag to compare

2.1.0 (2018-03-15)

Features

  • add ability to pass sync middlewares (15bdcb8)
  • CacheMiddleware: add clearOnMutation option (thanks @haruska) (0071220)

v2.0.0

03 Mar 08:17
Compare
Choose a tag to compare

2.0.0 (2018-03-03)

New

  • add beforeFetch option to RelayNetworkLayer(middlewares, { beforeFetch }). (c4b6f2c)

Code Refactoring

  • rename gqlErrorsMiddleware to errorMiddleware (5a5c3f5)

BREAKING CHANGES

  • renamed gqlErrorsMiddleware to errorMiddleware
  • subscribeFn should be provided as named option

Migration guide from v1 to v2

1. Rename gqlErrorsMiddleware to errorMiddleware

- import { RelayNetworkLayer, gqlErrorsMiddleware } from 'react-relay-network-modern';
+ import { RelayNetworkLayer, errorMiddleware } from 'react-relay-network-modern';

- const network = new RelayNetworkLayer([ gqlErrorsMiddleware() ]);
+ const network = new RelayNetworkLayer([ errorMiddleware() ]);

2. If you use subscriptions provide subscribeFn as named option:

- const network = new RelayNetworkLayer(middlewares, subscribeFn);
+ const network = new RelayNetworkLayer(middlewares, { subscribeFn });