react-user-safe-state
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

react-use-safe-state

GitHub license GitHub release PR's Welcome

react-use-safe-state is an utility hook that wraps around react's useState with the aim to prevent the occuring of the famous Can't perform a React state update on an unmounted component error.

Installation

# Yarn
yarn add react-use-safe-state

# NPM
npm install react-use-safe-state --save

Usage

Using react-use-safe-state is as simple as replacing useState hooks with useSafeState.

Package Sidebar

Install

npm i react-user-safe-state

Weekly Downloads

1

Version

1.0.0

License

MIT

Unpacked Size

10.8 kB

Total Files

13

Last publish

Collaborators

  • nickfla1