Get access to LocalStorage on Cross-Origin Domains.
Put the iframe.html
in your remote domain.
(async () => {
const ls = crossStorage('https://example.com/iframe.html');
await ls({ action: 'set', key: 'myKey', value: 'myValue' })';
const value = await ls({ action: 'get', key: 'myKey' });
// value: myValue
})()