chore: remove apollo 2.x and downgrade graphql to 15.x

This commit is contained in:
2022-07-05 23:05:08 +02:00
parent 2d1fa55f15
commit 5a112ba590
3 changed files with 70 additions and 1091 deletions
+3 -13
View File
@@ -1,22 +1,12 @@
import { ApolloClient } from 'apollo-client'
import {
InMemoryCache,
IntrospectionFragmentMatcher
} from 'apollo-cache-inmemory'
import { createHttpLink } from 'apollo-link-http'
import { setContext } from 'apollo-link-context'
import { ApolloClient, InMemoryCache, createHttpLink } from '@apollo/client/core'
import { setContext } from '@apollo/client/link/context'
import { provide } from '@vue/composition-api'
import { DefaultApolloClient } from '@vue/apollo-composable'
import introspectionQueryResultData from '../fragmentTypes.json'
import { useAuth } from './auth'
const apiUrl = process.env.graphqlApi || '/query'
const fragmentMatcher = new IntrospectionFragmentMatcher({
introspectionQueryResultData
})
const cache = new InMemoryCache({ fragmentMatcher })
const cache = new InMemoryCache()
const httpLink = createHttpLink({
uri: apiUrl