Skip to content

Latest commit

 

History

History
43 lines (29 loc) · 1.75 KB

File metadata and controls

43 lines (29 loc) · 1.75 KB

Grafbase ⨯ Apollo Client (Relay Pagination)

Join our Community

Please note

This example doesn't implement any authentication provider. You will need to add one to use this example in production — learn more.

Getting Started

  1. Run npx degit grafbase/grafbase/examples/react-apollo-relay-pagination grafbase-with-react-apollo-relay-pagination to clone this example
  2. Change directory into the new folder cd grafbase-with-react-apollo-relay-pagination
  3. Run npm install
  4. Run npx grafbase@latest dev in your terminal
  5. Populate the backend with some Post entries using a GraphQL mutation (make sure to repeat this a few times with different title values):
mutation {
  postCreate(input: { title: "Grafbase" }) {
    post {
      id
    }
  }
}
  1. In another terminal, run npm start and visit http://localhost:3000

Learn More About Grafbase

To learn more about Grafbase, take a look at the following resources:

  • Grafbase — learn about Grafbase features and API.
  • Pagination — learn about Grafbase pagination API.

To learn more about Apollo Client, take a look at the following resources:

Run on Codesandbox

Develop with Codesandbox