From 2cc0a1fbcecef1000e7f804067f0234e947f560c Mon Sep 17 00:00:00 2001 From: Dede Fuji Abdul Date: Tue, 27 Feb 2024 11:52:50 +0700 Subject: [PATCH] Update GraphQL and REST endpoints --- src/utils/graphql.ts | 6 +++--- src/utils/network.ts | 3 +-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/utils/graphql.ts b/src/utils/graphql.ts index 42650f3..98c8a4e 100755 --- a/src/utils/graphql.ts +++ b/src/utils/graphql.ts @@ -2,9 +2,9 @@ import { ApolloClient, createHttpLink, InMemoryCache } from '@apollo/client/core export const apolloClient = () => { - const httpLink = createHttpLink({ - uri: 'http://10.1.50.173:32180/graphql', - credentials: 'include', // Include credentials for cross-origin requests + const httpLink = createHttpLink({ + uri: import.meta.env.VITE_APP_GRAPHQL_ENDPOINT, + credentials: 'include', }); diff --git a/src/utils/network.ts b/src/utils/network.ts index 18e1822..f6bb137 100755 --- a/src/utils/network.ts +++ b/src/utils/network.ts @@ -1,7 +1,6 @@ import axios from 'axios' -const url = 'http://10.1.50.173:32181' +const url = import.meta.env.VITE_APP_REST_ENDPOINT as string const instance = axios.create({ - // baseURL: 'http://192.168.1.84:32180' baseURL: url })