import { ref as e, watch as t } from "vue";
import { notEmpty as n } from "@milaboratories/helpers";
var r = /* @__PURE__ */ new Map();
function i(t) {
	return r.has(t) || r.set(t, e(localStorage.getItem(t))), n(r.get(t), "...");
}
function a(e, t) {
	t == null ? localStorage.removeItem(e) : localStorage.setItem(e, t);
}
function o(e) {
	let n = i(e);
	return t(n, (t) => a(e, t)), n;
}
export { o as useLocalStorage };

//# sourceMappingURL=useLocalStorage.js.map