Javascript noob here, please excuse my stupidity-
Is there a way to access the local storage of another URL when I am not actively visiting that site?
If I am on https://www.youtube.com/ and I go to local storage on my browser (Chrome in this case), there are two separate URLs there, one for https://www.youtube.com/ and one for https://accounts.youtube.com/.
I don’t know how to go about accessing this "secondary" local storage, or whatever you would call it, for a website.
FOR EXAMPLE,
When I go to youtube.com, this is what the local storage looks like:

Note the two separate URLs in the Local Storage tab.
Each URL has it’s own respective local storage, with different values in each.
Local storage for https://www.youtube.com/

Local storage for https://accounts.youtube.com/

How would I go about accessing localStorage["foo"] from accounts.youtube.com?
Currently, localStorage["foo"] would just be undefined, because it is looking at the local storage for the primary url (https://www.youtube.com/) but I want to somehow access the "secondary" URL (https://accounts.youtube.com/)
So is there any way for me to access this "secondary" storage using Javascript, or am I simply looking at this the wrong way/misunderstanding something?
>Solution :
As others have said in the comments, this is not possible. It’s by design for security. Here is a pretty decent article that covers the same origin policy, localStorage, and sessionStorage.
https://auth0.com/blog/secure-browser-storage-the-facts/