diff --git a/src/util/IDB.js b/src/util/IDB.js index cc20de0..1ed7afe 100644 --- a/src/util/IDB.js +++ b/src/util/IDB.js @@ -8,6 +8,16 @@ function set(key, value) { }) localforage.setItem(key, value); } +async function get(key) { + localforage.config({ + driver: localforage.INDEXEDDB, + name: 'Nebula', + version: 1.0, + storeName: 'nebula_config', + description: 'Nebula Config for things reliant on IndexedDB' + }) + return await localforage.getItem(key); +} -export { set }; +export { set, get }