UNPKG

@macrostrat/column-components

Version:

React rendering primitives for stratigraphic columns

21 lines (20 loc) 520 B
"use strict"; Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" }); class LocalStorage { name; constructor(name) { this.get = this.get.bind(this); this.set = this.set.bind(this); this.name = name; } get() { const str = window.localStorage.getItem(this.name); return JSON.parse(str); } set(obj) { const str = JSON.stringify(obj); return window.localStorage.setItem(this.name, str); } } exports.LocalStorage = LocalStorage; //# sourceMappingURL=storage.cjs.map