]> git.immae.eu Git - github/bastienwirtz/homer.git/blobdiff - src/components/SettingToggle.vue
Initial Emby service commit
[github/bastienwirtz/homer.git] / src / components / SettingToggle.vue
index 985ca84f8f0c6344fa01395b062c8a72eb9599d3..6c8a10fa87a455accd9d25abbf5570a389fc4ca0 100644 (file)
@@ -12,6 +12,7 @@ export default {
     name: String,
     icon: String,
     iconAlt: String,
+    defaultValue: Boolean,
   },
   data: function () {
     return {
@@ -24,6 +25,8 @@ export default {
 
     if (this.name in localStorage) {
       this.value = JSON.parse(localStorage[this.name]);
+    } else {
+      this.value = this.defaultValue;
     }
 
     this.$emit("updated", this.value);