summaryrefslogtreecommitdiff
path: root/assets/js/base.js
diff options
context:
space:
mode:
Diffstat (limited to 'assets/js/base.js')
-rw-r--r--assets/js/base.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/assets/js/base.js b/assets/js/base.js
index 08287e42..75d23b88 100644
--- a/assets/js/base.js
+++ b/assets/js/base.js
@@ -65,6 +65,22 @@ var Kanboard = (function() {
return true;
},
+ // Save preferences in local storage
+ SetStorageItem: function(key, value) {
+ if (typeof(Storage) !== "undefined") {
+ localStorage.setItem(key, value);
+ }
+ },
+
+ GetStorageItem: function(key) {
+
+ if (typeof(Storage) !== "undefined") {
+ return localStorage.getItem(key);
+ }
+
+ return '';
+ },
+
// Generate Markdown preview
MarkdownPreview: function(e) {