alfonsusac / devscale-eventmaker

Yet another event maker app
https://devscale-eventmaker-alfonsusac.vercel.app
2 stars 0 forks source link

Auth: create a function to check session in the client. #61

Closed alfonsusac closed 9 months ago

alfonsusac commented 9 months ago

Cookie key: "token" Payload key in localstorage: "user"

This function is client-side only.

You may test (but you don't need to):

useEffect(()=>{
  console.log(session())
},[])