I would like to request the addition of the usePrevious hook to the @nanlabs/react-hooks library. This hook would be a React state hook that returns the previous state.
Use Case
I often find the need to track the previous state in my components, and having a dedicated hook for this functionality would be very useful.
Describe the feature
I would like to request the addition of the
usePrevious
hook to the@nanlabs/react-hooks
library. This hook would be a React state hook that returns the previous state.Use Case
I often find the need to track the previous state in my components, and having a dedicated hook for this functionality would be very useful.
Proposed Solution
Reference:
Usage example:
Other Information
No response
Acknowledgements
Version used
0.5.3
Environment details (OS name and version, etc.)
any