How is security risk of storing authentication token in localStorage compared with cookies?

I’ve read that it’s a bad idea to save Single Page App’s encrypted authentication token in browser’s localStorage because this makes your app vulnerable to XSS attack, and when the token is stolen, the hacker can disguise as… Continue reading How is security risk of storing authentication token in localStorage compared with cookies?