Skip to content

Instantly share code, notes, and snippets.

@olalekanteeblaze
Last active September 11, 2021 21:19
Show Gist options
  • Save olalekanteeblaze/a802fc089249262716a7629ab317843c to your computer and use it in GitHub Desktop.
Save olalekanteeblaze/a802fc089249262716a7629ab317843c to your computer and use it in GitHub Desktop.
import React from 'react';
import { render } from 'react-dom';
import {
ApolloClient,
InMemoryCache,
ApolloProvider,
} from "@apollo/client";
const client = new ApolloClient({
uri: 'https://countries.trevorblades.com/',
cache: new InMemoryCache()
});
function App() {
return (
<div>
<h2>My first Apollo app 🚀</h2>
</div>
);
}
render(
<ApolloProvider client={client}>
<App />
</ApolloProvider>,
document.getElementById('root'),
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment