Skip to content

Commit 032b762

Browse files
committed
fix: example
1 parent 7b78863 commit 032b762

4 files changed

Lines changed: 25 additions & 11 deletions

File tree

examples/graphql-yoga/fresh_graphql.gen.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
// This file is generated and updated by fresh_graphql during development.
33
// This file should be checked into source control.
44

5-
import * as $0 from "./graphql/Query/foo/mod.ts";
6-
import * as $1 from "./graphql/Subscription/countdown/mod.ts";
5+
import * as $0 from "./graphql/Query/joke.ts";
6+
import * as $1 from "./graphql/Subscription/countdown.ts";
77

88
const manifest = {
99
modules: {
10-
"Query/foo/mod.ts": $0,
11-
"Subscription/countdown/mod.ts": $1,
10+
"Query.joke": $0,
11+
"Subscription.countdown": $1,
1212
},
1313
baseUrl: import.meta.url,
1414
};

examples/graphql-yoga/graphql/Query/foo/mod.ts

Lines changed: 0 additions & 7 deletions
This file was deleted.
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
// Jokes courtesy of https://punsandoneliners.com/randomness/programmer-jokes/
2+
const JOKES = [
3+
"Why do Java developers often wear glasses? They can't C#.",
4+
"A SQL query walks into a bar, goes up to two tables and says “can I join you?”",
5+
"Wasn't hard to crack Forrest Gump's password. 1forrest1.",
6+
"I love pressing the F5 key. It's refreshing.",
7+
"Called IT support and a chap from Australia came to fix my network connection. I asked “Do you come from a LAN down under?”",
8+
"There are 10 types of people in the world. Those who understand binary and those who don't.",
9+
"Why are assembly programmers often wet? They work below C level.",
10+
"My favourite computer based band is the Black IPs.",
11+
"What programme do you use to predict the music tastes of former US presidential candidates? An Al Gore Rhythm.",
12+
"An SEO expert walked into a bar, pub, inn, tavern, hostelry, public house.",
13+
];
14+
15+
export const schema = /* GraphQL */ `
16+
extend type Query {
17+
joke: String!
18+
}
19+
`;
20+
21+
export const resolver = () => JOKES[Math.floor(Math.random() * JOKES.length)];

examples/graphql-yoga/graphql/Subscription/countdown/mod.ts renamed to examples/graphql-yoga/graphql/Subscription/countdown.ts

File renamed without changes.

0 commit comments

Comments
 (0)