How do I implement "Remember Me" functionality? My thought was to use sessionStorage instead of localStorage but how do I point supabase there? (Using nextjs/react if that matters)
c
chipilov
03/07/2022, 7:35 AM
Currently, Supabase.JS supports only 2 options for storing the JWT - in memory (i.e. it is lost after a page refresh) or localStorage (which is essentially "Remember Me" since it persists across refreshes and browser close/open)
chipilov
03/07/2022, 7:35 AM
You control this via the persistSession parameter passed to the SupabaseClient constructor
chipilov
03/07/2022, 7:35 AM
unfortunately, currently you would need to re-initialize supabase if you want to switch from one to the other
chipilov
03/07/2022, 7:36 AM
There is an open issue currently about adding this functionality to the UI library: