Codesandbox demos on aurelia.io don't load with third-party cookies disabled

Because I’ve got “Block third-party cookies” enabled by default, it seems to block access to localStorage

I’ve opened an issue at codesandbox-client and a quick browse through the code, it looks like there is a unused InMemoryStore that it could fall back to in this case.

Probably any online editor will fail to work without cookies enabled for their site. Not sure what can be done though. Will it work by just enabling InMemoryStore?

I didn’t realise that blocking third-party cookies also blocked third party localStorage access, but it looks like that is where all the errors are coming from.

The code has two implementations of SyncKeyValueStore, the LocalStorageStore and InMemoryStore. However, now I look a bit deeper, it looks like there are plenty of other usages of localStorage throughout that repository which it might be tripping up on.

I would need to debug a bundled version to get a better idea of where its actually breaking.

1 Like

I think many of the errors are caused by the debug module which uses localStorage in the browser and has no fallback:

1 Like

Looks like there is a fix:

1 Like