mirror of
https://github.com/wassname/talk.git
synced 2026-07-01 13:46:30 +08:00
WebStorage events
This commit is contained in:
@@ -82,7 +82,8 @@ export function clear() {
|
||||
}
|
||||
}
|
||||
|
||||
window.addEventListener('storage', function(e) {
|
||||
const msg = `${e.key} " was changed in page ${e.url} from ${e.oldValue} to ${e.newValue}`;
|
||||
console.log(msg);
|
||||
});
|
||||
// Enable this to debug WEB Storage events
|
||||
// window.addEventListener('storage', function(e) {
|
||||
// const msg = `${e.key} " was changed in page ${e.url} from ${e.oldValue} to ${e.newValue}`;
|
||||
// console.log(msg);
|
||||
// });
|
||||
|
||||
Reference in New Issue
Block a user