|
10 | 10 | <head> |
11 | 11 | <meta charset="UTF-8" /> |
12 | 12 | <meta name="viewport" content="width=device-width, initial-scale=1.0" /> |
13 | | - <title>GraphiQL 4 with React 19 and GraphiQL Explorer</title> |
| 13 | + <title>GraphiQL</title> |
14 | 14 | <style> |
15 | 15 | body { |
16 | 16 | margin: 0; |
|
31 | 31 | </style> |
32 | 32 | <link |
33 | 33 | rel="stylesheet" |
34 | | - href=" https://esm.sh/[email protected].0/dist/style.css" |
| 34 | + href=" https://esm.sh/[email protected].2/dist/style.css" |
35 | 35 | /> |
36 | 36 | <link |
37 | 37 | rel="stylesheet" |
38 | | - href=" https://esm.sh/@graphiql/[email protected].0/dist/style.css" |
| 38 | + href=" https://esm.sh/@graphiql/[email protected].2/dist/style.css" |
39 | 39 | /> |
40 | 40 | <!-- Note: the ?standalone flag bundles the module along with all of its `dependencies`, excluding `peerDependencies`, into a single JavaScript file. --> |
41 | 41 | <script type="importmap"> |
|
47 | 47 | "react-dom": "https://esm.sh/[email protected]", |
48 | 48 | "react-dom/client": "https://esm.sh/[email protected]/client", |
49 | 49 |
|
50 | | - "graphiql": "https://esm.sh/[email protected].0?standalone&external=react,react/jsx-runtime,react-dom,@graphiql/react", |
51 | | - "@graphiql/plugin-explorer": "https://esm.sh/@graphiql/[email protected].0?standalone&external=react,react/jsx-runtime,react-dom,@graphiql/react,graphql", |
52 | | - "@graphiql/react": "https://esm.sh/@graphiql/react@0.30.0?standalone&external=react,react/jsx-runtime,react-dom,graphql,@graphiql/toolkit", |
| 50 | + "graphiql": "https://esm.sh/[email protected].2?standalone&external=react,react/jsx-runtime,react-dom,@graphiql/react", |
| 51 | + "@graphiql/plugin-explorer": "https://esm.sh/@graphiql/[email protected].2?standalone&external=react,react/jsx-runtime,react-dom,@graphiql/react,graphql", |
| 52 | + "@graphiql/react": "https://esm.sh/@graphiql/react@0.32.0?standalone&external=react,react/jsx-runtime,react-dom,graphql,@graphiql/toolkit", |
53 | 53 |
|
54 | 54 | "@graphiql/toolkit": "https://esm.sh/@graphiql/[email protected]?standalone&external=graphql", |
55 | 55 | "graphql": "https://esm.sh/[email protected]" |
56 | 56 | } |
57 | 57 | } |
58 | 58 | </script> |
59 | 59 | <script type="module"> |
| 60 | +<!-- inject --> |
60 | 61 | // Import React and ReactDOM |
61 | 62 | import React from 'react'; |
62 | 63 | import ReactDOM from 'react-dom/client'; |
|
66 | 67 | import { explorerPlugin } from '@graphiql/plugin-explorer'; |
67 | 68 |
|
68 | 69 | const fetcher = createGraphiQLFetcher({ |
69 | | - url: 'https://countries.trevorblades.com', |
| 70 | + url: JUNIPER_URL, |
| 71 | + subscriptionUrl: normalizeSubscriptionEndpoint(JUNIPER_URL, JUNIPER_SUBSCRIPTIONS_URL) |
70 | 72 | }); |
71 | 73 | const explorer = explorerPlugin(); |
72 | 74 |
|
|
0 commit comments