Explorar o código

add auto save

tripeur %!s(int64=4) %!d(string=hai) anos
pai
achega
fdd0343a1d
Modificáronse 1 ficheiros con 3 adicións e 0 borrados
  1. 3 0
      src/PlannerApp.vue

+ 3 - 0
src/PlannerApp.vue

@@ -102,6 +102,9 @@ export default defineComponent({
       this.localSave();
     };
   },
+  unmounted() {
+    this.save();
+  },
   methods: {
     localSave() {
       window.localStorage.setItem("activeState", JSON.stringify(this.$store.getters.getJSONState));