Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 10The final step involves deploying your new GraphQL API to the Edge with the help of GitHub. Here's how you can do it: Sign in to your GitHub account, or create one if you don't have it yet. Initiate a new repository via GitHub. In the Grafbase Das...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 9Grafbase provides support for edge caching, a feature that enhances performance by serving already cached data, thereby eliminating the need to wait for a response from the database. Inside grafbase/grafbase.config.ts we will update the config export...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 8We're now ready to finish the last piece of the GraphQL API by adding a new query that fetches all products from the Fauna Database. Inside grafbase/grafbase.config.ts add the following query definition: g.query('products', { resolver: 'products/al...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 7We will now create a GraphQL query to fetch data from the Fauna Database. We'll be using the productByInput input type we created earlier. Inside grafbase/grafbase.config.ts add the following product query: g.query('product', { args: { by: g.inputR...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 6In this step, we'll create a GraphQL mutation to delete products from the Fauna collection. To do this, update the grafbase/grafbase.config.ts file to include the following: const productDeletePayload = g.type('ProductDeletePayload', { deleted: g.b...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 5Let's now move on to creating a GraphQL mutation to update products by ID. Let's begin by updating the Grafbase Configuration to add a mutation that accepts the following arguments: by — something we can use to pass id to target the product we want ...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 4We're now ready to create a GraphQL mutation that we will use to add to our products collection inside the Fauna database. A GraphQL mutation is a type of operation in GraphQL that modifies data on the server and typically look something like this: m...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 3Let's begin by installing the Fauna JavaScript driver inside our project so that we can use it inside our first resolver: npm install fauna graphql Now create the file grafbase/resolvers/create.ts. We'll complete this inside the next step but for no...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 2Fauna is perfect for creating databases and databases inside of databases where you require multi-tenant support for building and scaling applications. We'll be using a single database in this guide as well as the UI for creating a database and colle...Build and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon
Jamie Bartongrafbase.hashnode.dev·Aug 7, 2023Build and Deploy a GraphQL API to the Edge with Fauna — Part 1In this series, we will build a GraphQL API with Grafbase, and persist data with Fauna. Here's a breakdown of what we'll be building: This is part 1 Set up a Fauna Database Install and configure Fauna inside Grafbase Resolvers Create Product Muta...27 readsBuild and Deploy a GraphQL API to the Edge with FaunaGrafbase Hackathon