diff --git a/package.json b/package.json index 25f6f6f..66675dc 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "build": "vite build", "preview": "vite preview", "check": "svelte-check --tsconfig ./tsconfig.json", - "deploy": "npx gh-pages -d dist" + "deploy": "npx gh-pages -d dist -b gh-pages" }, "devDependencies": { "@iconify/icons-ic": "^1.2.11", diff --git a/src/lib/CounterApp/CounterApp.svelte b/src/lib/CounterApp/CounterApp.svelte index 3b30341..fc8db9f 100644 --- a/src/lib/CounterApp/CounterApp.svelte +++ b/src/lib/CounterApp/CounterApp.svelte @@ -21,6 +21,8 @@ function save_data(data: any) { anything_changed = false; } //#endregion + +// @ts-ignore $: counters_data, (anything_changed = true); //#region variables initialize @@ -34,13 +36,14 @@ $: { if (anything_changed == false) { break $; } else { - anything_changed = + anything_changed = // @ts-ignore Array.from(counters_saved) === Array.from(counters_data) ? false : true; } } onMount(() => { if (localStorage.getItem("counters_saved") !== null) { + // @ts-ignore counters_data = Array.from(get(counters_saved)); counter_count = counters_data[counters_data.length - 1].id; } @@ -110,13 +113,11 @@ function handle_save() {