swr
GitHub describes it as React Hooks for Data Fetching. The repository metadata lists TypeScript as its primary language. The metadata lists the MIT license. This article stays within the project description and details documented in the GitHub repository README.
vercel/swr: Introduction
GitHub describes it as React Hooks for Data Fetching. The repository metadata lists TypeScript as its primary language. The metadata lists the MIT license. This article stays within the project description and details documented in the GitHub repository README.
Repository scope
GitHub describes it as React Hooks for Data Fetching. The repository metadata lists TypeScript as its primary language. The metadata lists the MIT license. The README describes the project this way: The name “ SWR ” is derived from stale-while-revalidate , a cache invalidation strategy popularized by HTTP RFC 5861. SWR first returns the data from cache (stale), then sends the request (revalidate), and finally comes with the up-to-date data again.
Introduction
The README section "Introduction" states: With just one hook, you can significantly simplify the data fetching logic in your project. And it also covered in all aspects of speed, correctness, and stability to help you build better experiences:
Introduction
The README section "Introduction" states: - Fast , lightweight and reusable data fetching - Transport and protocol agnostic - Built-in cache and request deduplication - Real-time experience - Revalidation on focus - Revalidation on network recovery - Polling - Pagination and scroll position recovery - SSR and SSG - Local mutation (Optimistic UI) - Built-in smart error retry - TypeScript - React Suspense - React Native
Introduction
The README section "Introduction" states: With SWR, components will get a stream of data updates constantly and automatically . Thus, the UI will be always fast and reactive .
Editorial conclusion
The repository README is the source for this review. It does not replace a local installation or an independent test.
Community notes