Hello
I ran into an issue while using the Flow JavaScript SDK (FCL) in my project. After logging in with a wallet; everything worked fine until the user refreshed the page.
The wallet state didn’t persist properly & fcl.currentUser() would sometimes return null; breaking parts of the app. ![]()
To fix this; I created a small wrapper around fcl.currentUser().subscribe() to manage the wallet state manually on page load.
This made the app much more stable. If you are facing something similar; the FCL Authentication Guide helped me a lot.
Also; for anyone new and wondering what is javascript it’s the programming language used to build interactive websites, and in this case, it’s what we use to connect to Flow wallets using FCL. ![]()
Hope this helps someone!
Thank you !! ![]()