"use client";
import graphqlDataProvider, { ClientError, gql, GraphQLClient, RequestDocument } from "@refinedev/graphql";
import { GraphQLError, parse } from "graphql";
export const API_URL = process.env.NEXT_PUBLIC_API_URL as string;
const MAX_RETRIES = 3;
const RETRY_DELAY = 500;
type AuthResponse = {
data: unknown | null;
errors: GraphQLError[];
};
export const client = new GraphQLClient(API_URL, {
credentials: "include",
});
export const dataProvider = graphqlDataProvider(client);
"use client";
import graphqlDataProvider, { ClientError, gql, GraphQLClient, RequestDocument } from "@refinedev/graphql";
import { GraphQLError, parse } from "graphql";
export const API_URL = process.env.NEXT_PUBLIC_API_URL as string;
const MAX_RETRIES = 3;
const RETRY_DELAY = 500;
type AuthResponse = {
data: unknown | null;
errors: GraphQLError[];
};
export const client = new GraphQLClient(API_URL, {
credentials: "include",
});
export const dataProvider = graphqlDataProvider(client);