Apparently AnkiDesktops localStorage is not working anymore?
I updated to the newest version and certain options from my templates are not being saved anymore.
If anyone wants to recreate this problem:
<script>
var STORAGE_KEY = "example-storage-location";
var existing_storage = localStorage.getItem(STORAGE_KEY);
if (existing_storage === null)
{
existing_storage = 0;
} else
{
existing_storage = parseInt(existing_storage);
}
console.log("This template has been accessed " + existing_storage + " times.");
existing_storage = existing_storage + 1;
localStorage.setItem(STORAGE_KEY, existing_storage);
console.log(STORAGE_KEY + " set to " + existing_storage);
</script>
This is a modification of the code from a testcase for the same bug on AnkiDroid: [BUG]: localStorage does not seem to be persistent in version 2.17.5 · Issue #15911 · ankidroid/Anki-Android · GitHub.
This here is happening on AnkiDesktop too! After restarting Anki completely, the localStorage is wiped.
Is anyone able to recreate this problem? I don’t want to open a bug entry on gitHub, when there is still a chance that I am the only one affected by it.
I am using the newest Version of Anki (24.06.2-windows-qt6)