You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(utils): subscribe method of createJSONStorage should only run in the client (#2585)
* fix: prevent calling storage subscribe unless in client
* test: add test for getStringStorage method from createJSONStorage to not be called in server
* use try-catch
* Revert "test: add test for getStringStorage method from createJSONStorage to not be called in server"
This reverts commit 71d2fa0.
* test: checking localStorage/sessionStorage access with createJSONStorage in server
* test: improve checking localStorage/sessionStorage access with createJSONStorage in server
* test: use defineProperty for checking localStorage/sessionStorage access with createJSONStorage in server
* fix: ts error in new test
* improve detecting browser storage access in client
* Update src/vanilla/utils/atomWithStorage.ts
* patch console.warn for atomWithStorage (in non-browser environment) test
---------
Co-authored-by: daishi <[email protected]>
Co-authored-by: Daishi Kato <[email protected]>
0 commit comments