React Activation

screenshot of React Activation
react

Hack <KeepAlive /> for React

Overview:

The React Activation library provides a way to implement the <keep-alive /> functionality seen in Vue for React applications. It also mentions official support for <Offsreen /> in React 18.x, offering a more stable <KeepAlive /> function with babel pre-compilation. Additionally, it is compatible with React v16/v17/v18 and Preact v10+.

Features:

  • Implement <keep-alive /> functionality in React
  • Compatible with React v16/v17/v18 and Preact v10+
  • More stable <KeepAlive /> function with babel pre-compilation
  • Cache Control for managing cache manually
  • Supports lifecycle methods for both ClassComponent and FunctionComponent
  • Online Demo and more examples available
  • Closable tabs with react-router and umi
react
React

React is a widely used JavaScript library for building user interfaces and single-page applications. It follows a component-based architecture and uses a virtual DOM to efficiently update and render UI components

rollup
Rollup

RollupJS is a popular and efficient JavaScript module bundler that takes the code from multiple modules and packages them into a single optimized file, minimizing the overall size of the application and improving its performance.