Relay is a JavaScript framework for building data-driven React applications.
MIT License
Bot releases are visible (Hide)
Published by alunyov over 5 years ago
Commits: https://github.com/facebook/relay/compare/v2.0.0-rc.1...v2.0.0-rc.2
graphql-compiler
into relay-compiler
(#2593)environment.unstable_internal.getSelector(...)
has changed.ReactRelayContext
is now exported from react-relay
.Viewer
, Query
, or a type that implements Node
). No user api is provided yet.ConcreteRequest
to provide more flexibility for our fetching apis.Published by jstejada almost 6 years ago
Commits: https://github.com/facebook/relay/compare/v1.7.0-rc.1...v2.0.0-rc.1
Added a new relay-experimental
package which exposes a few experimental APIs.
Published by jstejada almost 6 years ago
Commits: https://github.com/facebook/relay/compare/v1.6.2...v1.7.0
This release comes with two exciting contributions from external contributors:
While we at Facebook only support JS and Flow flavored JS and generate optional Flow types, supporting TypeScript had been difficult. #2293 by @alloy does the required refactoring to allow other developers to write plugins to add this missing support.
Create React App tries to minimize dependencies, so including Relay's Babel plugin for everyone didn't make much sense. This meant that using Relay with Create React App wasn't possible without ejecting.
This release adds babel-plugin-relay/macro (@apalm, #2171) which in the upcoming [email protected] will make it possible to use Relay without ejecting powered by babel-plugin-macros (http://yarn.pm/babel-plugin-macros).
Published by kassens about 6 years ago
This release doesn't contain many commits, but comes with two exciting additions from external contributors:
While we at Facebook only support JS and Flow flavored JS and generate optional Flow types, supporting TypeScript had been difficult. #2293 by @alloy does the required refactoring to allow other developers to write plugins to add this missing support.
Create React App tries to minimize dependencies, so including Relay's Babel plugin for everyone didn't make much sense. This meant that using Relay with Create React App wasn't possible without ejecting.
This release adds babel-plugin-relay/macro
(@apalm, #2171) which in the upcoming [email protected]
will make it possible to use Relay without ejecting powered by babel-plugin-macros
.
relay-compiler
is no longer a peerDependency of relay-runtime
as it's not needed during deployment. Make sure to keep all Relay packages at the same version! (@kassens)RelayNetwork.streamQuery
and RelayNetwork.sendSubscription
Published by jstejada about 6 years ago
Fixed:
Published by jstejada about 6 years ago
Commits: https://github.com/facebook/relay/compare/v1.6.0...master
Potentially Breaking:
graphql
peer dependency to ^0.13.0
React.forwardRef
. This is a breaking change for people relying on the relayContainer.refs.component
implementation detail.New:
@relay
(mask: false)
directive for fragment *definitions: *Applied to a fragment definition, @relay(mask: false)
changes the generated Flow types to be more usable when the fragment is spread with the same directive; The Flow types will no longer be exact objects and no longer contain internal marker fields.Fixed:
refetchConnection
in Pagination ContainerRelayConnectionHandler
now properly writes page_info
after refetching a connectionRelayContainerUtils
didn't recognize React.forwardRef
as React.Component
mutation
or subscription
updater functionsImproved:
relay-runtime
, set main entry in relay-runtime package.json
.dedupeJSONStringify
is now more effectiverelay-compiler
by caching client schema extensions.applyOptimisticUpdate
on RelayModern.relay-compiler
can now compile JS files with optionalChaining
syntax.relay-compiler
can now compile JS files with nullishCoalescingOperator
syntax.relay-compiler
can now compile JS files with optionalCatchBinding
syntax.relay-compiler
has better warnings when required variables are not passed in.relay-compiler
now generates operation Flow types: 5d83328.fbjs
dependency to 0.8.17
.fast-glob
dependency to 2.2.2
.Published by jstejada over 6 years ago
Commits: https://github.com/facebook/relay/compare/v1.5.0...v1.6.0
Breaking:
^16.3.0
Potentially Breaking:
__type__
fieldsFixed:
jest --watch
work with React 16Improved:
graphql-compiler
out of relay-compiler
as its own independent packagegraphql
a peer dependencygraphql-js
to v0.13.2relay-compiler
: Makes flow generated '%future added value'
for enums optionalPublished by jstejada over 6 years ago
This release introduces several changes, some of the most relevant ones are highlighted here.
New:
.graphql
files. Extensions only work on existing types, and does not currently support adding client-only types to the schema.dataFrom
prop.ConcreteNode
format supporting Batch requests.Potentially Breaking:
src
to the relay-compiler
(#2346).RelayNetwork.execute
to return a RelayObservable
with variables
and node
, in addition to the QueryPayload
. However, RelayNetwork.create
maintains the same API (c058ffc4).Fixed:
RelayConcreteVariables
(03985855).RANGE_ADD
mutation (7f2013d6).Improved:
getIdentifierForSelection
.NoFragmentCyclesRule
; can now use Fragments recursively.RecordSourceInspector
which is of marginal value, especially now that we have a useful devtools app.—quiet
.graphql.experimental
.New:
New:
const {Observable} = require('relay-runtime')
to use Relay's lightweight Observable implementation which seeks to follow the Observable specification.yarn add relay-devtools
) (86b63d44a2228705975294d4bfcd34ea2de88f92)graphql.experimental
All features now supported directly in graphql
literal tags. (9afd76498942ef8c7c8de64c6bfc5b1da2a1dd65)Observer
when loading more data (ef7aa5bf2963d4de592a86109b2bec0a9931b813)Potentially Breaking:
execute()
and executeMutation()
(0202673f046cd9a52181388c9910ab1e6082e803)Fixed:
@include
in classic/compat mode (d65291156865c52e67e6afb0473a07879979b54d)__typename
and id
in the correct order (95319d19c2027661efd400eea3137ba7b6885431)@arguments
in compat mode (1ce348a5bc472a58607279c08e2236b8459b5877)@argumentDefinitions
would not be validated first (50803a5c3951ff7f34fa46bc5ad774fba12dc111)Published by kassens about 7 years ago
A small update since 1.2.0 that mainly exposes a few new internals.
New:
graphql
tags now support null
literal values (@nkohari e7962fb9338b41ed3c9a302384d26a86b7514c0a)RelayEnvironment
to use Observables instead of Promises to prepare for streaming and other advanced usages (@leebyron)formatGeneratedModule
on relay-compiler
to allow more customization of the compiler (@robrichard 7b440133446681d660d785c11c137d029fcf804f)--validate
to relay-compiler
to validate without writing files (@ajhyndman af35c307e16e613e4dee46dba040c0c990919b3c)RelayConnectionInterface
is now injectable for legacy clients (@kassens d9c1eb08f043e369dc5d584968b96d5c3bd11ad9)Fixed:
RelayRecordProxy#setValue
now accepts arrays of scalar values (@kassens 7a2b27ea0e93d37857358707f40a2ededef0cfdc)eslint-config-fbjs
dependency from relay-compiler
(@mwalkerwells 7b914f0ec7b49004a9d63107884e501a92020b95)Published by leebyron about 7 years ago
In addition to all of the changes in v1.2.0-rc1, v1.2.0 includes:
New:
@inline
to @relay(mask: false)
(c7235ab93d832f3f41f6c728a0dc9e5549d31c5d) and can be used in both Relay modern and Relay compat (20327fd8b4af2ae3c8a254d8878f74c9d3d63e4a)pageInfo
when using pagination controllers (9686119769ea8fb7da684215a572fdeee2a1f92e)Fixed:
Improved:
peerDep
between relay-runtime and relay-compiler to create early warnings if dependencies are misaligned (25826464fd4e0778e518d417d1ede04686a2ea68)Published by kassens over 7 years ago
This release is another massive collection of some exciting new features, fixed bugs and improved error messages and warnings. Thanks to our external contributors, summer interns and anyone helping with code or bug reports.
New
@inline
directive to inline fragments verbatim for use in utility functions (1b19ee0fb536fd9b28d25fd7b02801256870d68c)--exclude
and --include
for more control over what files are parsed (94c8b203a95b1366b4034459d1c594e092de92ee)Fixed
Improved
graphql
tags (7e1065fd6ea2cbc5e3468029ac2f0ab3b7daf418)loadMore
and refetch
of the pagination and refetch container is now consistently called after render (e316b6e70c06f03dc4a1160342f1f7c73dc59b20).js.flow
files (3e0266c649e993e704f07bb8484cae8938112a71)^0.10.5
(beba4077be30c80327d41dc4871c09c4a9bdabb5)Published by leebyron over 7 years ago
Relay v1.1.0 represents a massive number of improvements atop the release of Relay v1.0 last month, including improved error messages, bug fixes, and a handful of new utilities. Special thanks to the Relay team's summer interns, who contributed a number of the improvements below:
Minor breaking:
Set
, Map
, and Promise
are no longer bundled into Relay. (#1870)babel-relay-plugin
has been officially removed in favor of babel-plugin-relay
(753f1f070e41883788b29ea5e0d87abfce668bdc)babel-plugin-relay
. Previously this would insert throw
statements into the compiled output, now this produces compiler errors. (c7634da4453f37b804c14230e920839273421767)New:
componentRef
to get a ref of the contained component (3571fb9530c5decde1da5ae10fd45179eebc82ba)Fixes:
Viewer
type supported correctly (daf38f24b861a76c6acfbd3217e3043a699af991)@relay(plural)
(#1810)Published by leebyron over 7 years ago
Today, we're releasing Relay Modern, a new version of Relay designed from the ground up to be easier to use, more extensible, and most of all to improve performance on mobile devices.
Install the release candidate of react-relay
:
yarn add react-relay
Once updating to v1.0, require('react-relay')
will return the Relay Modern API. For existing Relay apps, update your code to require the existing Relay Classic API: require('react-relay/classic')
.
Relay Compiler and Babel plugin:
In development, Relay Modern relies on a Babel plugin (just as Relay Classic does). Relay Modern also uses a compiler to generate runtime code.
yarn add --dev babel-plugin-relay relay-compiler
Once updating to v1.0, the new babel-plugin-relay
plugin works with both Relay Modern and Relay Classic, replacing the legacy babel-relay-plugin
. It uses much simpler configuration which should feel familiar to your .babelrc files.
Published by leebyron over 7 years ago
More minor issues fixed in this next RC. Thanks to the community for continuing to report after using Relay Modern!
Changes since rc.3:
getResponse()
on Record Source Proxy objects.retry()
method in QueryRenderer ready statePublished by leebyron over 7 years ago
Continued thanks to the community for their help in reporting and fixing issues in for Relay Modern! We hope you'll keep trying out the release candidates and continue to report how its going.
Changes since rc.2:
relay-compiler
including ignoring node_modules
and supporting custom file extensions.Published by leebyron over 7 years ago
Thanks to the community for their help in identifying and fixing issues in our first release candidate of Relay Modern! Here's a fresh second Release Candidate with some fixes for the primary issues encountered by early adopters. We hope you'll try it out and continue to report how it goes for you.
Changes since rc.1
:
relay-compiler --watch
now actually watches your files. (#1654)import from 'react-relay'
) no longer includes any compatibility layer (#1631)prop-types
instead of using React.PropTypes
to allow using React v15.5 without warningsuploaders
API to Network in Relay Modern and Classic.Published by leebyron over 7 years ago
Today, we're releasing a first release candidate of Relay Modern, a new version of Relay designed from the ground up to be easier to use, more extensible, and most of all to improve performance on mobile devices.
Install the release candidate of react-relay
:
yarn add react-relay@dev
Once updating to v1.0, require('react-relay')
will return the Relay Modern API. For existing Relay apps, update your code to require the existing Relay Classic API: require('react-relay/classic')
.
Relay Compiler and Babel plugin:
In development, Relay Modern relies on a Babel plugin (just as Relay Classic does). Relay Modern also uses a compiler to generate runtime code.
yarn add --dev babel-plugin-relay@dev relay-compiler@dev
Once updating to v1.0, the new babel-plugin-relay
plugin works with both Relay Modern and Relay Classic, replacing the legacy babel-relay-plugin
. It uses much simpler configuration which should feel familiar to your .babelrc files.
Published by leebyron over 7 years ago
Changes since v1.0.0-alpha.3