Using Relay

If you’re looking for a more opinionated, prepackaged GraphQL framework for your application, Relay is the gold standard. With an API that’s been reimagined since its initial release in 2015, it’s lighter, faster, and easier to use than before. “Relay Modern,” as it’s called, is worth a serious look when you evaluate a GraphQL framework for your application.

Let’s reimplement our PlateSlate user interface using Relay Modern.

As with our Apollo example in the previous section, we’ll use the create-react-app package to build the boilerplate for our new Relay application, just to save some time:

​ ​$ ​​create-react-app​​ ​​plate-slate-relay-ui​

Once our application is generated, we can verify that ...

Get Craft GraphQL APIs in Elixir with Absinthe now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.