]> git.r.bdr.sh - rbdr/forum/blame - src/config/apollo.js
Add jest for testing
[rbdr/forum] / src / config / apollo.js
CommitLineData
58f7d521
RBR
1import fetch from 'cross-fetch';
2import { ApolloClient, HttpLink, InMemoryCache } from '@apollo/client/core';
c1bc5993
RBR
3import { apollo as apolloConfig } from './config';
4
5const cache = new InMemoryCache();
6
7export const client = new ApolloClient({
8 cache,
58f7d521
RBR
9 link: new HttpLink({
10 uri: apolloConfig.uri,
11 fetch
12 }),
c1bc5993
RBR
13 ...apolloConfig
14});