Kong/swrv
Stale-while-revalidate data fetching for Vue observed · 2026-08-28
Health v2 · maintenance only
79/100
- Activity 96
- Release rhythm 44
- Longevity 100
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-03. Adoption (stars, forks) is never an input.
- gap_med: 425
- age_days: 2412
- days_rel: 163
- days_push: 29
- n_releases_24m: 2
Adoption not part of the score
2277 stars · 75 forks observed · 2026-08-28
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-30, confidence not recorded
swrv is a Vue Composition API library for remote data fetching using the stale-while-revalidate caching strategy. It serves cached data immediately, revalidates in the background, and provides features like polling, revalidation on focus, request deduplication, and error retry.
Use cases
- fetch remote data in Vue components with automatic caching
- show stale data instantly while revalidating in the background
- poll an API at intervals to keep the UI up to date
- deduplicate duplicate in-flight requests across components
- refetch data when the window regains focus
- retry failed requests with stale-if-error fallback
- plug in a custom cache like localStorage
When to avoid
- you need SSR support, which was removed as of version 0.10.0
- your project uses React (use the swr library instead)
- you need a full state management solution rather than a data-fetching hook
- you're on Vue 2.6 or below and can't use an older release
Facets
library · maturity active
http-client caching state-management middleware frontend web-development developer-tools browser cross-platform vue swr stale-while-revalidate data-fetching composition-api typescript reactivity nodejs
3 sources
- readme: https://github.com/Kong/swrv · fetched 2026-08-28 · e67bbca6d93f
- homepage: https://docs-swrv.netlify.app · fetched 2026-08-29 · 71bd4f9a908b
- registry_npm: https://registry.npmjs.org/swrv · fetched 2026-08-29 · dd62e57ba722
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| Kong/swrv | main | 79 |
For agents
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem