1import React from 'react';
2import { Client, Provider, fetchExchange } from 'urql';
3import { persistedExchange } from '@urql/exchange-persisted';
4
5import LocationsList from './LocationsList';
6
7const client = new Client({
8 url: 'https://trygql.formidable.dev/graphql/apq-weather',
9 exchanges: [
10 persistedExchange({
11 preferGetForPersistedQueries: true,
12 }),
13 fetchExchange,
14 ],
15});
16
17function App() {
18 return (
19 <Provider value={client}>
20 <LocationsList />
21 </Provider>
22 );
23}
24
25export default App;