Storage
With web storage, web applications can store data locally within the user's browser.
useLocalStorage
Sync state to local storage so that it persists through a page refresh. Usage is similar to useState except we pass in a local storage key so that we can default to that value on page load instead of the specified initial value.
Usage
useSessionStorage
Sync state to session storage so that it persists through a page refresh. Usage is similar to useState except we pass in a local storage key so that we can default to that value on page load instead of the specified initial value.
Usage
Last updated
Was this helpful?