Implementing Offset‑Based Pagination in Apollo Client with InMemoryCache
Learn how to store each page of a list under a unique cache key and use fetchMore to append new results without reloading the whole dataset.
ReadMeFeed / Community knowledge
Real questions. Useful conversations. Find the people who know your stack.
Learn how to store each page of a list under a unique cache key and use fetchMore to append new results without reloading the whole dataset.
fetchMore can return the correct page while the normalized cache renders duplicates or snaps back to page one. Here is how to tell which cache setting is responsible.
Stop mixing Redux with Apollo. Learn how to use InMemoryCache normalization for server data and Reactive Variables for local UI state to create a single source of truth.
Learn how to use Apollo Client's InMemoryCache to eliminate stale data through normalization, custom typePolicies, and direct cache manipulation.
When writing integration tests for an Apollo Server schema, the goal is to verify that resolver logic works alongside any custom Express middleware (such as request‑level logging, CORS handling, or rate‑limiting) without relying on production credentials or making real network calls. The createTestClient utility from @apollo/server/testing provides an in‑pro
Apollo Client's InMemoryCache utilizes typePolicies to define how incoming data is merged into the normalized store. When dealing with paginated lists or filtered result sets, the default merge behavior may not align with specific UI requirements for data retention or deduplication. The goal is to implement a custom merge function that prevents the overwriti
Apollo Client utilizes apollo3-cache-persist to mirror the in-memory cache to local storage, enabling state recovery across browser sessions. During the hydration phase, the client restores the persisted state to the InMemoryCache before the application becomes interactive. A challenge arises when the application schema is updated between sessions. If the pe