Skip to content

Commit

Permalink
Doc "Getting started" typo fix (#9939)
Browse files Browse the repository at this point in the history
  • Loading branch information
gilgardosh committed Apr 25, 2024
1 parent f583257 commit c15e2a4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions website/src/pages/docs/getting-started/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ Most client-side implementations without GraphQL Code Generator would query the
```tsx
import { useQuery } from 'urql'

interface PostQuery {
interface PostsQuery {
posts: {
id: string
title: string
Expand Down Expand Up @@ -88,7 +88,7 @@ const Posts = () => {
import { request, gql } from 'graphql-request'
import { useQuery } from '@tanstack/react-query'

interface PostQuery {
interface PostsQuery {
posts: {
id: string
title: string
Expand All @@ -115,7 +115,7 @@ const postsQueryDocument = gql`
`

const Posts = () => {
const { data } = useQuery<PostQuery>('posts', async () => {
const { data } = useQuery<PostsQuery>('posts', async () => {
const { posts } = await request(endpoint, postsQueryDocument)
return posts
})
Expand Down Expand Up @@ -336,7 +336,7 @@ const postsQueryDocument = graphql(/* GraphQL */ `

const Posts = () => {
// React Query `useQuery()` knows how to work with typed graphql documents
const { data } = useQuery<PostQuery>('posts', async () => {
const { data } = useQuery<PostsQuery>('posts', async () => {
const { posts } = await request(endpoint, postsQueryDocument)
return posts
})
Expand Down

0 comments on commit c15e2a4

Please sign in to comment.