
Ilia Sokolov
Uchi.ru
In this presentation, we will take a deep dive into client-side caching—a powerful yet often underappreciated mechanism.
We'll start with the basics of HTTP caching. I will explain how cache validation works using ETag and Last-Modified headers, and why the binary “fresh/stale” logic is often insufficient.
Then, we'll look at how these limitations are being addressed by Service Workers, which give developers full programmatic control over the cache. However, they also introduce their own complexity and potential for conflicts. I will show why they are not a silver bullet and when they are truly worth using.
Next, we'll move on to modern client-side libraries: from transport-level caching with Axios Cache Interceptor to state integration with TanStack Query, which transforms API data into part of the UI state, complete with request deduplication and optimistic updates.
Finally, I will discuss how and why to measure caching effectiveness, specifically on the client side. All of this will help you build an effective caching strategy that guarantees a fast and responsive user interface.
Uchi.ru