razage / persistent-flannel

a website for tracking what games you've played and getting recommendations
0 stars 0 forks source link

Set some localstorage values #24

Closed razage closed 7 years ago

razage commented 7 years ago

Localstorage is probably the best way to track whether someone is logged in or not via javascript. Nothing security-critical should be there (at least I don't think it should), but some stuff like username and user_id would be fine. Since I'm already returning this data via JSON on successful login, it shouldn't be too difficult to take that data and shove it into localstorage.