Skip to content

Commit

Permalink
chore(docs/examples): fix refernces to server.url x2
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonkuhrt committed Sep 6, 2024
1 parent 108969e commit 8e78757
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
headers: Headers {
accept: 'application/graphql-response+json; charset=utf-8, application/json; charset=utf-8',
'content-type': 'application/json',
'x-sent-at-time': '1725655670901'
'x-sent-at-time': '1725656299249'
},
signal: undefined,
method: 'post',
Expand Down
2 changes: 1 addition & 1 deletion scripts/generate-examples-derivatives/generate-docs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ import $1 from './$2/__.js'`,
// This is not something that the website examples support showing.
// It would required bringing in analysis of the server code for twoslash.
// URL references are replaced with localhost URL literals.
.replaceAll(`server.url`, `"http://localhost:3000/graphql"`)
.replaceAll(`server.url`, `\`http://localhost:3000/graphql\``)
.replaceAll(/.*server.*\n(?:\s*\n)?/g, ``)

return {
Expand Down
2 changes: 1 addition & 1 deletion website/content/examples/transport-http-dynamic-headers.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ await graffle.rawString({ document: `{ languages { code } }` })
headers: Headers {
accept: 'application/graphql-response+json; charset=utf-8, application/json; charset=utf-8',
'content-type': 'application/json',
'x-sent-at-time': '1725655670901'
'x-sent-at-time': '1725656299249'
},
signal: undefined,
method: 'post',
Expand Down
1 change: 1 addition & 0 deletions website/content/examples/transport-http-method-get.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import { Pokemon } from './pokemon/__.js'

const graffle = Pokemon
.create({
schema: `http://localhost:3000/graphql`,
transport: { methodMode: `getReads` }, // [!code highlight]
})
.use(async ({ exchange }) => {
Expand Down

0 comments on commit 8e78757

Please sign in to comment.