Added
- Added
@appendNode
and@prependNode
declarative mutation directives for inserting a node to connections (#3155) [0fe732d]- Usage:
comments @appendNode(connections: $connections, edgeTypeName: "CommentEdgeType") { id }
- Usage:
- Added
@deleteEdge
directive for removing the edge from connections (#3177) [01d65b3]- Usage:
deletedCommentId @deleteEdge(connections: $connections)
- Usage:
- Added plural support for
@deleteRecord
directive (#3135) [27f938c]- Usage:
deletedCommentIds @deleteRecord
- Usage:
- Made scheduleGC a public function inside RelayModernStore (#3167) [97401cb]
- Added cacheConfig in RequestDescriptor (#3070) … [eb256a3]
Improvements
- Remove fragment naming enforcement from JS compiler [ff1c10b]
Fixed
- Docs: fix typos of the 'A Guided Tour' page (#3236) [e4413bf]
- Fix prependNode and prependEdge in declarative connection [7c836df]
- Fix warning for plural fragment ref pointing to null data [c1a6831]
- Don't setTimeout in loadQuery in SSR [2da0325]
- Fix @match with __typename: other in MatchContainer [92c8d68]
- Fix conflicting field value warning [7e3deb4]
- Bugfix for validating optimistic updates containing undefined fields … [6a1586d]
- Dispose nested entrypoints when calling dispose() [d5352a2]
Misc
- In @relay/react-relay, we now use
^16.9.0 || ^17
as apeerDependency
.
Experimental
- Added various minor improvements and fixes to the
loadQuery
API. useQueryLoader
now accepts an initial query reference.- Prevent
usePreloadedQuery
from consuming stale cached query refs - Stop caching errors at fragment boundaries, which prevented
- Warn when attempting to use an already disposed PreloadedQuery or PreloadedEntryPoint [187bd34]
- Make sure loadQuery requests are deduped when started (vs at render time) [a21b1cb]
- Add Relay log event for when an EntryPointContainer uses an entrypoint component resource [7818bfb]
- Create type utility EntryPointElementConfig [7d02240]
- Unsubscribe network requests when releasing temporary retains [933b280]
- Optimize getFragmentIdentifier [ac3a252]
- holdGC for incremental responses in QueryExecutor [b3ecce2]
Relay Compiler in Rust
The Relay team is actively working on the new compiler implemented in Rust. The majority of recent changes you can see in the repo are related to the compiler. This new version won't be included in the release, as we are still working on the migration strategies for our OSS customers.
Thank you for all outstanding contribution to the Relay compiler (#3182)