const ls = window.localStorage;
export const storage = {
    get: (key) => ls.getItem(key),
    set: (key, value) => ls.setItem(key, value),
    toggle: (key, force) => {
        if (typeof force === 'undefined') {
            force = !ls.getItem(key);
        }
        if (force) {
            ls.setItem(key, '1');
        }
        else {
            ls.removeItem(key);
        }
        return force;
    },
};
//# sourceMappingURL=storage.js.map