<p align="center">
  <img width="180" src="./logo.svg" alt="Logo" />
</p>

<h1 align="center">tanstack-router-keepalive</h1>
<p align="center">Route-level keepalive for @tanstack/react-router</p>

## Introduction

`tanstack-router-keepalive` is a route-level keepalive solution for `@tanstack/react-router`. It provides a way to cache the component instance when the route is switched, and reuse it when the route is switched back.

## Online Demo

[Click Here](https://hemengke1997.github.io/tanstack-router-keepalive/)

## Features

- Route level keepalive
- Excellent performance: keepalive route components do not enter the react rendering process
- Easy to use: one component to rule them all
- Flexible control: provide API to control route cache and lifecycle

Read the [documentation](https://hemengke1997.github.io/tanstack-router-keepalive-docs/) for more details.

## License

Distributed under the [MIT license](/LICENSE.md).
