forked from MapComplete/MapComplete
Refactoring fullscreenhandling
This commit is contained in:
parent
e1a4c75391
commit
00f610c589
23 changed files with 346 additions and 245 deletions
|
@ -5,7 +5,7 @@ export class LocalStorageSource {
|
|||
static Get(key: string, defaultValue: string = undefined): UIEventSource<string> {
|
||||
try {
|
||||
const saved = localStorage.getItem(key);
|
||||
const source = new UIEventSource<string>(saved ?? defaultValue);
|
||||
const source = new UIEventSource<string>(saved ?? defaultValue, "localstorage:"+key);
|
||||
|
||||
source.addCallback((data) => {
|
||||
localStorage.setItem(key, data);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue