# \#web

**URL:** https://community.apollographql.com/tag/web/3.md?page=1

[Latest](https://community.apollographql.com/latest.md) · [Categories](https://community.apollographql.com/categories.md) · [Tags](https://community.apollographql.com/tags.md)

**Page:** 2

---

## [Parse JSON response to GraphQL](https://community.apollographql.com/t/parse-json-response-to-graphql/8755)

<div class="topic-metadata">

**Author:** [@Amit\_M](https://community.apollographql.com/u/Amit_M)\
**Replies:** 1\
**Last updated:** [March 22, 2025, 7:46am UTC](https://community.apollographql.com/t/parse-json-response-to-graphql/8755 "2025-03-22T07:46:48Z")

</div>

How can I parse a stored JSON response in React and pass to a component that is expecting graphql response? This is what I am trying, but it is not reading the data correctly: const client = new ApolloClient({ cache:…

---

## [Apollo Client v4 alpha releases are here!](https://community.apollographql.com/t/apollo-client-v4-alpha-releases-are-here/8719)

<div class="topic-metadata">

**Author:** [@JeffAuriemma](https://community.apollographql.com/u/JeffAuriemma)\
**Replies:** 0\
**Last updated:** [March 18, 2025, 4:51pm UTC](https://community.apollographql.com/t/apollo-client-v4-alpha-releases-are-here/8719 "2025-03-18T16:51:54Z")

</div>

I’ve got good news and better news. The good news is that Apollo Client 4.0 alphas are now being released: The better news is that this comes with ESM support and a significantly smaller bundle size, see the changelo…

---

## [Comparable useIsMutating hook from TanStack Query](https://community.apollographql.com/t/comparable-useismutating-hook-from-tanstack-query/8705)

<div class="topic-metadata">

**Author:** [@ericchernuka](https://community.apollographql.com/u/ericchernuka)\
**Replies:** 4\
**Last updated:** [March 14, 2025, 12:31am UTC](https://community.apollographql.com/t/comparable-useismutating-hook-from-tanstack-query/8705 "2025-03-14T00:31:24Z")

</div>

I’m wondering if there’s a way to get determine if any mutations are occuring like in TanStack Query’s useIsMutating hook. We have few places where getting the status is challenging due to it being a child and a parent i…

---

## [Conditionally using preloadQuery](https://community.apollographql.com/t/conditionally-using-preloadquery/8697)

<div class="topic-metadata">

**Author:** [@ericchernuka](https://community.apollographql.com/u/ericchernuka)\
**Replies:** 2\
**Last updated:** [March 12, 2025, 1:47am UTC](https://community.apollographql.com/t/conditionally-using-preloadquery/8697 "2025-03-12T01:47:16Z")

</div>

We’re leveraging TanStack Router and are realy loving the ability to kick off an Apollo request outside of React, but we ran into an interesting issue where we need to conditionally call a preloadQuery which presents mor…

---

## [@nonreactive directive not working as expected](https://community.apollographql.com/t/nonreactive-directive-not-working-as-expected/8653)

<div class="topic-metadata">

**Author:** [@rdelga80](https://community.apollographql.com/u/rdelga80)\
**Replies:** 14\
**Last updated:** [March 6, 2025, 4:20pm UTC](https://community.apollographql.com/t/nonreactive-directive-not-working-as-expected/8653 "2025-03-06T16:20:58Z")

</div>

This is for web. I’m trying to implement @nonreactive in my codebase but I really can’t get it to work. The only problem that I think might be happening is that the fragment that needs to be nonreactive is deeply neste…

---

## [Alice in Wonderland: Federation on the other side of the mirror](https://community.apollographql.com/t/alice-in-wonderland-federation-on-the-other-side-of-the-mirror/8686)

<div class="topic-metadata">

**Author:** [@Aleksandar\_Susnjar](https://community.apollographql.com/u/Aleksandar_Susnjar)\
**Replies:** 0\
**Last updated:** [March 6, 2025, 2:53pm UTC](https://community.apollographql.com/t/alice-in-wonderland-federation-on-the-other-side-of-the-mirror/8686 "2025-03-06T14:53:20Z")

</div>

What we love about Federation is that it can take a complex supergraph request and distribute the processing of it to relevant subgraphs. It takes one thing, creates multiple, aggregates responses and sends them back (we…

---

## [Problems with ETag header that - schema.py](https://community.apollographql.com/t/problems-with-etag-header-that-schema-py/8551)

<div class="topic-metadata">

**Author:** [@Jensileus](https://community.apollographql.com/u/Jensileus)\
**Replies:** 1\
**Last updated:** [February 18, 2025, 5:05pm UTC](https://community.apollographql.com/t/problems-with-etag-header-that-schema-py/8551 "2025-02-18T17:05:31Z")

</div>

I am trying to create ETags with my subrahp. I want to implement logic in all my subgraph so we check ETag and dont fetch if nothing has changed. This is good both for server, and client. But ut seems like Apollo Router…

---

## [Update apollo client to latest version](https://community.apollographql.com/t/update-apollo-client-to-latest-version/8352)

<div class="topic-metadata">

**Author:** [@kristalshards](https://community.apollographql.com/u/kristalshards)\
**Replies:** 1\
**Last updated:** [February 4, 2025, 8:23pm UTC](https://community.apollographql.com/t/update-apollo-client-to-latest-version/8352 "2025-02-04T20:23:09Z")

</div>

Hi, is it safe to update apollo client to the latest version or anything close to it? We have 3.8.4 in our app and I’ve read through the changelog and I am not completely sure if there are any breaking changes between 3.…

---

## [\`value.toString\` is not a function issue](https://community.apollographql.com/t/value-tostring-is-not-a-function-issue/7992)

<div class="topic-metadata">

**Author:** [@jerelmiller](https://community.apollographql.com/u/jerelmiller)\
**Replies:** 2\
**Last updated:** [February 4, 2025, 6:15pm UTC](https://community.apollographql.com/t/value-tostring-is-not-a-function-issue/7992 "2025-02-04T18:15:54Z")

</div>

Since December 5, we have received some reports from Apollo Client users encountering an ApolloError with the message: value.toString is not a function. After thorough investigation, we determined that this issue is not…

---

## [Mock resolvers and query arguments](https://community.apollographql.com/t/mock-resolvers-and-query-arguments/7122)

<div class="topic-metadata">

**Author:** [@Jeff\_Lowery](https://community.apollographql.com/u/Jeff_Lowery)\
**Replies:** 1\
**Last updated:** [January 31, 2025, 5:09pm UTC](https://community.apollographql.com/t/mock-resolvers-and-query-arguments/7122 "2025-01-31T17:09:58Z")

</div>

Continuing the discussion from Do mock resolvers take inputs?: The above was posted back in Oct '21, and got no reply. It’s still a valid question, as the documentation does not show an example. So, to ask again: Can a…

---

## [Is there a sample using Subscriptions and Intersection Observer](https://community.apollographql.com/t/is-there-a-sample-using-subscriptions-and-intersection-observer/8058)

<div class="topic-metadata">

**Author:** [@shipswake](https://community.apollographql.com/u/shipswake)\
**Replies:** 1\
**Last updated:** [January 31, 2025, 5:06pm UTC](https://community.apollographql.com/t/is-there-a-sample-using-subscriptions-and-intersection-observer/8058 "2025-01-31T17:06:33Z")

</div>

I need to create a list with infinite scrolling. I would like to use Apollo Client Graphql Subscriptions and the Intersection Observer. Is there an example of how I can implement this in a React app?

---

## [I am using Apollo server and Apollo client and graphql. I am using Pagination in my website. When I click on paginator after some pages it lost the cookies and doesn't verify the user and then gives error](https://community.apollographql.com/t/i-am-using-apollo-server-and-apollo-client-and-graphql-i-am-using-pagination-in-my-website-when-i-click-on-paginator-after-some-pages-it-lost-the-cookies-and-doesnt-verify-the-user-and-then-gives-error/7962)

<div class="topic-metadata">

**Author:** [@priyakumari](https://community.apollographql.com/u/priyakumari)\
**Replies:** 1\
**Last updated:** [January 31, 2025, 4:50pm UTC](https://community.apollographql.com/t/i-am-using-apollo-server-and-apollo-client-and-graphql-i-am-using-pagination-in-my-website-when-i-click-on-paginator-after-some-pages-it-lost-the-cookies-and-doesnt-verify-the-user-and-then-gives-error/7962 "2025-01-31T16:50:14Z")

</div>

---

## ["Cannot read property \_location of null" when testing with Jest and react-testing-library](https://community.apollographql.com/t/cannot-read-property-location-of-null-when-testing-with-jest-and-react-testing-library/7915)

<div class="topic-metadata">

**Author:** [@boileroo](https://community.apollographql.com/u/boileroo)\
**Replies:** 1\
**Last updated:** [January 31, 2025, 4:45pm UTC](https://community.apollographql.com/t/cannot-read-property-location-of-null-when-testing-with-jest-and-react-testing-library/7915 "2025-01-31T16:45:40Z")

</div>

Hi, I am encountering this issue intermittently but regularly when testing my NextJS React application using Jest and react-testing-library: "Cannot read property \_location of null" This happens, I believe, because th…

---

## [How to run a GQL Query against mock data to get realistic results in unit tests?](https://community.apollographql.com/t/how-to-run-a-gql-query-against-mock-data-to-get-realistic-results-in-unit-tests/7805)

<div class="topic-metadata">

**Author:** [@Gabriel\_Faria](https://community.apollographql.com/u/Gabriel_Faria)\
**Replies:** 1\
**Last updated:** [January 31, 2025, 4:35pm UTC](https://community.apollographql.com/t/how-to-run-a-gql-query-against-mock-data-to-get-realistic-results-in-unit-tests/7805 "2025-01-31T16:35:14Z")

</div>

I’m looking for a way to run a query against a mock data object. The problem I currently mock the GQL response via \<MockedProvider mocks={mocks}\>. That works great, but the mock’s result comes back exactly as defined. …

---

## [Progress bar for Apollo client upload](https://community.apollographql.com/t/progress-bar-for-apollo-client-upload/7844)

<div class="topic-metadata">

**Author:** [@Barz](https://community.apollographql.com/u/Barz)\
**Replies:** 0\
**Last updated:** [September 23, 2024, 4:20am UTC](https://community.apollographql.com/t/progress-bar-for-apollo-client-upload/7844 "2024-09-23T04:20:54Z")

</div>

Hi, I’m using React frontend and Nodejs Backend. I want to add a progress bar on my frontend. Here is my apolloClient setup: Blockquote import { ApolloClient, InMemoryCache } from ‘@apollo/client’; import createUp…

---

## [Help with Mutation Error: Argument Missing](https://community.apollographql.com/t/help-with-mutation-error-argument-missing/7721)

<div class="topic-metadata">

**Author:** [@dely\_adman](https://community.apollographql.com/u/dely_adman)\
**Replies:** 0\
**Last updated:** [July 25, 2024, 6:42am UTC](https://community.apollographql.com/t/help-with-mutation-error-argument-missing/7721 "2024-07-25T06:42:26Z")

</div>

Hey everyone, I’m running into a bit of trouble with a mutation and could use some advice. I’m working on a GraphQL setup and I keep getting this error: Mutation "createUser" requires argument "email" but none was prov…

---

## [WebSocket connection to 'ws://localhost:4000/graphql' failed:](https://community.apollographql.com/t/websocket-connection-to-ws-localhost-4000-graphql-failed/7674)

<div class="topic-metadata">

**Author:** [@Muhammad-Asad-Mughal](https://community.apollographql.com/u/Muhammad-Asad-Mughal)\
**Replies:** 0\
**Last updated:** [July 1, 2024, 6:23am UTC](https://community.apollographql.com/t/websocket-connection-to-ws-localhost-4000-graphql-failed/7674 "2024-07-01T06:23:49Z")

</div>

import { PropsWithChildren, useMemo } from 'react'; import { ApolloClient, InMemoryCache, ApolloProvider as ApolloClientProvider, split, HttpLink, ApolloLink, } from '@apollo/client'; import { setContext } fr…

---

## [Generate cache id per each item in argument list](https://community.apollographql.com/t/generate-cache-id-per-each-item-in-argument-list/7378)

<div class="topic-metadata">

**Author:** [@ayyappa\_gollu](https://community.apollographql.com/u/ayyappa_gollu)\
**Replies:** 0\
**Last updated:** [April 12, 2024, 3:07pm UTC](https://community.apollographql.com/t/generate-cache-id-per-each-item-in-argument-list/7378 "2024-04-12T15:07:48Z")

</div>

I have a schema like this: type Product { uuid:string! name: string! } type City { uuid:string! name: string! } type CityProducts{ city: City! products: \[Product!\]! } type Query { citiesProducts(cityIds: \[In…

---

## [Apollo Client cache not feasible for large data sets?](https://community.apollographql.com/t/apollo-client-cache-not-feasible-for-large-data-sets/8104)

<div class="topic-metadata">

**Author:** [@jhgrund](https://community.apollographql.com/u/jhgrund)\
**Replies:** 10\
**Last updated:** [January 23, 2025, 2:23pm UTC](https://community.apollographql.com/t/apollo-client-cache-not-feasible-for-large-data-sets/8104 "2025-01-23T14:23:10Z")

</div>

Hey :slight\_smile: We’re using Apollo Client, and are in general satisfied. However, we’ve run into performance issues for some of our clients that have very large accounts, which leads to some large requests and store …

---

## [Access to raw mutation response in React](https://community.apollographql.com/t/access-to-raw-mutation-response-in-react/8060)

<div class="topic-metadata">

**Author:** [@antonk](https://community.apollographql.com/u/antonk)\
**Replies:** 0\
**Last updated:** [January 7, 2025, 5:21pm UTC](https://community.apollographql.com/t/access-to-raw-mutation-response-in-react/8060 "2025-01-07T17:21:13Z")

</div>

TL;DR; Is there a way to access mutation response before it is written to cache? The actual use case is a mutation that creates a client object and returns the new client ID and secret. I want to be able to show the s…

---

## ["Failed to execute 'transaction' on 'IDBDatabase'?](https://community.apollographql.com/t/failed-to-execute-transaction-on-idbdatabase/8048)

<div class="topic-metadata">

**Author:** [@vikr00001](https://community.apollographql.com/u/vikr00001)\
**Replies:** 1\
**Last updated:** [January 6, 2025, 9:39am UTC](https://community.apollographql.com/t/failed-to-execute-transaction-on-idbdatabase/8048 "2025-01-06T09:39:30Z")

</div>

I got this error on the client in production: Failed to execute ‘transaction’ on ‘IDBDatabase’: The database connection is closing. I rarely see that. I asked one of the LLMs about it, and in the prompt I mentioned …

---

## [Refreshing access and refresh tokens via Apollo in React](https://community.apollographql.com/t/refreshing-access-and-refresh-tokens-via-apollo-in-react/1440)

<div class="topic-metadata">

**Author:** [@Alexander\_Matviienko](https://community.apollographql.com/u/Alexander_Matviienko)\
**Replies:** 8\
**Last updated:** [December 22, 2024, 5:46pm UTC](https://community.apollographql.com/t/refreshing-access-and-refresh-tokens-via-apollo-in-react/1440 "2024-12-22T17:46:16Z")

</div>

I am trying to implement the logic for working with refresh and access tokens through Apollo in React. In the process of writing the code, I ran into the following problems. If the server (Graphql) returns me an error…

---

## [React query and subscription cache](https://community.apollographql.com/t/react-query-and-subscription-cache/8028)

<div class="topic-metadata">

**Author:** [@Notalifeform](https://community.apollographql.com/u/Notalifeform)\
**Replies:** 3\
**Last updated:** [December 20, 2024, 10:07am UTC](https://community.apollographql.com/t/react-query-and-subscription-cache/8028 "2024-12-20T10:07:43Z")

</div>

Hi, We’re using Apollo in react to use both queries and subscription with a Hasura backend server- as per the instructions here - see the code below. This seems to work fine, but we see that the cache is not shared betw…

---

## [Help to avoid repeated calls of apollo-client the parent component when called in the child component with the matching \_\_typename](https://community.apollographql.com/t/help-to-avoid-repeated-calls-of-apollo-client-the-parent-component-when-called-in-the-child-component-with-the-matching-typename/8019)

<div class="topic-metadata">

**Author:** [@NikG77](https://community.apollographql.com/u/NikG77)\
**Replies:** 6\
**Last updated:** [December 19, 2024, 1:22pm UTC](https://community.apollographql.com/t/help-to-avoid-repeated-calls-of-apollo-client-the-parent-component-when-called-in-the-child-component-with-the-matching-typename/8019 "2024-12-19T13:22:19Z")

</div>

Hi! Help to avoid repeated calls of apollo-client the parent component when called in the child component with the matching \_\_typename

---

## [More resilient code with data masking in Apollo Client 3.12](https://community.apollographql.com/t/more-resilient-code-with-data-masking-in-apollo-client-3-12/8000)

<div class="topic-metadata">

**Author:** [@jerelmiller](https://community.apollographql.com/u/jerelmiller)\
**Replies:** 0\
**Last updated:** [December 12, 2024, 4:46pm UTC](https://community.apollographql.com/t/more-resilient-code-with-data-masking-in-apollo-client-3-12/8000 "2024-12-12T16:46:02Z")

</div>

We are excited to announce the release of Apollo Client 3.12 with data masking :tada:. Data masking makes your applications more resilient to change by ensuring that only the fields requested by your component are avail…

---

## [Apollo Sandbox, Subscription and connectionParams?](https://community.apollographql.com/t/apollo-sandbox-subscription-and-connectionparams/5457)

<div class="topic-metadata">

**Author:** [@MrDesjardins](https://community.apollographql.com/u/MrDesjardins)\
**Replies:** 5\
**Last updated:** [December 9, 2024, 1:01pm UTC](https://community.apollographql.com/t/apollo-sandbox-subscription-and-connectionparams/5457 "2024-12-09T13:01:18Z")

</div>

Hello, I’m using the subscription pattern described in the Apollo Doc for onConnect and validation of JWT using the connectionParams. It works well when using a client that can insert the connectionParams information. H…

---

## [Missing await in a test that uses userEvent.click](https://community.apollographql.com/t/missing-await-in-a-test-that-uses-userevent-click/7960)

<div class="topic-metadata">

**Author:** [@Oskii2311](https://community.apollographql.com/u/Oskii2311)\
**Replies:** 0\
**Last updated:** [November 25, 2024, 7:34am UTC](https://community.apollographql.com/t/missing-await-in-a-test-that-uses-userevent-click/7960 "2024-11-25T07:34:53Z")

</div>

In the official documentation, there is an example of mutation testing (link to example). One of the assertions checks if the loading state is present in the DOM. This example uses user-event (GitHub link). According to …

---

## [Upgrade from 3.6.9 to 3.11.10](https://community.apollographql.com/t/upgrade-from-3-6-9-to-3-11-10/7944)

<div class="topic-metadata">

**Author:** [@Van\_Dao\_Vo](https://community.apollographql.com/u/Van_Dao_Vo)\
**Replies:** 1\
**Last updated:** [November 13, 2024, 9:24am UTC](https://community.apollographql.com/t/upgrade-from-3-6-9-to-3-11-10/7944 "2024-11-13T09:24:02Z")

</div>

I’m planning to upgrade @apollo/client from 3.6.9 to 3.11.10 for my PROD to use variableMatcher and maxUsageCount. I read CHANGELOG and did not see anything that could affect my PROD. Any advise about this? Thank you

---

## [ERROR: could not identify unique query](https://community.apollographql.com/t/error-could-not-identify-unique-query/7932)

<div class="topic-metadata">

**Author:** [@dameradev](https://community.apollographql.com/u/dameradev)\
**Replies:** 2\
**Last updated:** [November 7, 2024, 10:54am UTC](https://community.apollographql.com/t/error-could-not-identify-unique-query/7932 "2024-11-07T10:54:40Z")

</div>

Hello, we recently updated to “@apollo/experimental-nextjs-app-support”; We need this to run server queries. The problem is that now our global store queries are throwing the error below when on first page visit/refresh…

---

## ["rehackt" is causing unexpected behavior changes with React](https://community.apollographql.com/t/rehackt-is-causing-unexpected-behavior-changes-with-react/7814)

<div class="topic-metadata">

**Author:** [@abrenoch](https://community.apollographql.com/u/abrenoch)\
**Replies:** 7\
**Last updated:** [November 4, 2024, 5:12pm UTC](https://community.apollographql.com/t/rehackt-is-causing-unexpected-behavior-changes-with-react/7814 "2024-11-04T17:12:56Z")

</div>

Hey there, was trying out version 3.11.8 of the client and found myself encountering some completely new and unexpected behavior from React (v18.2.0) For some context, the UI has tabs that swap out the contents of some …

[Previous page](https://community.apollographql.com/tag/web/3.md?match_all_tags=true&tags%5B%5D=web)

[Next page](https://community.apollographql.com/tag/web/3.md?match_all_tags=true&page=2&tags%5B%5D=web)
