react-wire-persisted 2.0.0 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/client.js CHANGED
@@ -55,4 +55,4 @@ export function HydrationProvider({ children, onUpgrade, autoUpgrade = true }) {
55
55
  }
56
56
 
57
57
  // Re-export the hook from the main package for convenience
58
- export { useHydration } from './dist/react-wire-persisted.js'
58
+ export { useHydration } from './dist/react-wire-persisted.js'
package/client.mjs CHANGED
@@ -16,7 +16,7 @@ const isLocalStorageAvailable = () => {
16
16
  window.localStorage.setItem(testKey, 'test')
17
17
  window.localStorage.removeItem(testKey)
18
18
  return true
19
- } catch (e) {
19
+ } catch (_) {
20
20
  return false
21
21
  }
22
22
  }
@@ -30,10 +30,11 @@ const fakeStorage = {
30
30
  },
31
31
  removeItem: (key) => {
32
32
  delete fakeStorage.data[key]
33
- }
33
+ },
34
34
  }
35
35
 
36
36
  // Get current storage (real or fake)
37
+ // biome-ignore lint/correctness/noUnusedVariables: client usage only
37
38
  const getCurrentStorage = () => {
38
39
  return isLocalStorageAvailable() ? window.localStorage : fakeStorage
39
40
  }
@@ -52,7 +53,7 @@ const upgradeStorageToReal = () => {
52
53
  try {
53
54
  // Move data from fake to real storage
54
55
  const fakeData = { ...fakeStorage.data }
55
- Object.keys(fakeData).forEach(key => {
56
+ Object.keys(fakeData).forEach((key) => {
56
57
  if (fakeData[key] != null) {
57
58
  window.localStorage.setItem(key, fakeData[key])
58
59
  }
@@ -61,7 +62,7 @@ const upgradeStorageToReal = () => {
61
62
  // Clear fake storage
62
63
  fakeStorage.data = {}
63
64
  return true
64
- } catch (e) {
65
+ } catch (_) {
65
66
  return false
66
67
  }
67
68
  }
@@ -105,4 +106,4 @@ export function HydrationProvider({ children, onUpgrade, autoUpgrade = true }) {
105
106
  }, [autoUpgrade, onUpgrade])
106
107
 
107
108
  return children
108
- }
109
+ }
package/dist/index.js CHANGED
@@ -1,74 +1,75 @@
1
- import { createWire as U } from "@forminator/react-wire";
2
- import { useRef as b, useEffect as O } from "react";
1
+ import { useRef as A, useEffect as T } from "react";
2
+ import { createWire as k } from "@forminator/react-wire";
3
3
  (function() {
4
- const s = {};
4
+ const e = {};
5
5
  try {
6
6
  if (process) {
7
- process.env = Object.assign({}, process.env), Object.assign(process.env, s);
7
+ process.env = Object.assign({}, process.env), Object.assign(process.env, e);
8
8
  return;
9
9
  }
10
10
  } catch {
11
11
  }
12
- globalThis.process = { env: s };
12
+ globalThis.process = { env: e };
13
13
  })();
14
- const y = {}, w = (s) => {
15
- y[s] = s;
16
- }, j = (s) => w(s), x = () => y, N = (s, e = null) => {
17
- const t = e || y;
18
- return s ? Object.keys(t).reduce((r, o) => ({
19
- ...r,
20
- [o]: `${s}.${t[o]}`
21
- }), {}) : t;
22
- }, g = {
14
+ const p = {
23
15
  __IS_FAKE_LOCAL_STORAGE__: !0
24
- }, h = {
25
- getItem: (s) => g[s],
26
- setItem: (s, e) => {
27
- g[s] = e;
16
+ }, S = {
17
+ getItem: (e) => p[e],
18
+ setItem: (e, t) => {
19
+ p[e] = t;
28
20
  },
29
- removeItem: (s) => {
30
- delete g[s];
21
+ removeItem: (e) => {
22
+ delete p[e];
31
23
  },
32
24
  // Make Object.keys() work properly for _resetAll method
33
- ...g
25
+ ...p
34
26
  };
35
- let S = !1, p = !1;
36
- typeof window < "u" && (S = !0, document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", () => {
37
- p = !0;
38
- }) : p = !0);
39
- const m = () => S, _ = () => p, d = () => {
40
- if (!S) return !1;
27
+ let w = !1, R = !1, O = !1;
28
+ typeof window < "u" && (w = !0, document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", () => {
29
+ R = !0;
30
+ }) : R = !0);
31
+ const u = () => w, I = () => R, b = () => O, U = () => {
32
+ O = !0;
33
+ }, y = () => {
34
+ if (!w) return !1;
41
35
  try {
42
- const s = "__rwp_test__";
43
- return window.localStorage.setItem(s, "test"), window.localStorage.removeItem(s), !0;
36
+ const e = "__rwp_test__";
37
+ return window.localStorage.setItem(e, "test"), window.localStorage.removeItem(e), !0;
44
38
  } catch {
45
39
  return !1;
46
40
  }
47
- }, A = (s) => {
48
- const e = typeof s;
49
- return s === null ? !0 : Array.isArray(s) || e === "object" ? !1 : e !== "function";
50
- }, k = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
41
+ }, P = {}, N = (e) => {
42
+ P[e] = e;
43
+ }, F = (e) => N(e), x = () => P, K = (e, t = null) => {
44
+ const s = t || P;
45
+ return e ? Object.keys(s).reduce((r, n) => (r[n] = `${e}.${s[n]}`, r), {}) : s;
46
+ }, G = (e) => {
47
+ const t = typeof e;
48
+ return e === null ? !0 : Array.isArray(e) || t === "object" ? !1 : t !== "function";
49
+ }, z = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
51
50
  __proto__: null,
52
- addKey: w,
53
- fakeLocalStorage: h,
54
- getHasHydrated: _,
55
- getIsClient: m,
51
+ addKey: N,
52
+ fakeLocalStorage: S,
53
+ getHasHydrated: I,
54
+ getHasHydratedStorage: b,
55
+ getIsClient: u,
56
56
  getKeys: x,
57
- getPrefixedKeys: N,
58
- isLocalStorageAvailable: d,
59
- isPrimitive: A,
60
- key: j
57
+ getPrefixedKeys: K,
58
+ isLocalStorageAvailable: y,
59
+ isPrimitive: G,
60
+ key: F,
61
+ markStorageAsHydrated: U
61
62
  }, Symbol.toStringTag, { value: "Module" }));
62
- class I {
63
+ class E {
63
64
  /**
64
65
  * Initializes the class
65
66
  * @param {String} namespace Namespace to prefix all keys with. Mostly used for the logging & reset functions
66
67
  * @param {Object} registry (Optional) Initialize the storage provider with an existing registry
67
68
  */
68
- constructor(e, t) {
69
- if (new.target === I)
69
+ constructor(t, s) {
70
+ if (new.target === E)
70
71
  throw TypeError("StorageProvider is abstract. Extend this class to implement it");
71
- this.namespace = e || null, this.registry = t || /* istanbul ignore next */
72
+ this.namespace = t || null, this.registry = s || /* istanbul ignore next */
72
73
  {};
73
74
  }
74
75
  /**
@@ -77,22 +78,22 @@ class I {
77
78
  * @param {String} namespace New namespace for this storage provider
78
79
  */
79
80
  /* istanbul ignore next */
80
- setNamespace(e) {
81
+ setNamespace(t) {
81
82
  }
82
83
  /**
83
84
  * Registers an item with it's initial value. This is used for logging, resetting, etc.
84
85
  * @param {String} key Storage item's key
85
86
  * @param {*} initialValue Storage item's initial value
86
87
  */
87
- register(e, t) {
88
- this.registry[e] = t;
88
+ register(t, s) {
89
+ this.registry[t] = s;
89
90
  }
90
91
  /**
91
92
  * Reads an item from storage
92
93
  * @param {String} key Key for the item to retrieve
93
94
  */
94
95
  /* istanbul ignore next */
95
- getItem(e) {
96
+ getItem(t) {
96
97
  }
97
98
  /**
98
99
  * Stores a value
@@ -100,7 +101,7 @@ class I {
100
101
  * @param {String} value Item's value to store
101
102
  */
102
103
  /* istanbul ignore next */
103
- setItem(e, t) {
104
+ setItem(t, s) {
104
105
  }
105
106
  /**
106
107
  * Removes an item from storage
@@ -108,7 +109,7 @@ class I {
108
109
  * @param {Boolean} fromRegistry (Optional) If the item should also be removed from the registry
109
110
  */
110
111
  /* istanbul ignore next */
111
- removeItem(e, t = !1) {
112
+ removeItem(t, s = !1) {
112
113
  }
113
114
  /**
114
115
  * Gets all stored keys & values
@@ -118,13 +119,13 @@ class I {
118
119
  getAll() {
119
120
  }
120
121
  /**
121
- *
122
+ *
122
123
  * @param {Boolean} useInitialValues If values should be replaced with their initial values. If false, keys are removed
123
124
  * @param {String[]} excludedKeys (Optional) List of keys to exclude
124
125
  * @param {Boolean} clearRegistry (Optional) If the registry should also be cleared
125
126
  */
126
127
  /* istanbul ignore next */
127
- _resetAll(e = !0, t = [], r = !1) {
128
+ _resetAll(t = !0, s = [], r = !1) {
128
129
  }
129
130
  /**
130
131
  * Resets all values to their initial values
@@ -132,7 +133,7 @@ class I {
132
133
  * @param {String[]} excludedKeys (Optional) List of keys to exclude
133
134
  */
134
135
  /* istanbul ignore next */
135
- resetAll(e = []) {
136
+ resetAll(t = []) {
136
137
  }
137
138
  /**
138
139
  * Removes all items from local storage.
@@ -140,81 +141,69 @@ class I {
140
141
  * @param {String[]} excludedKeys (Optional) List of keys to exclude
141
142
  */
142
143
  /* istanbul ignore next */
143
- removeAll(e = []) {
144
+ removeAll(t = []) {
144
145
  }
145
146
  }
146
- class T extends I {
147
- constructor(e = null, t = {}) {
148
- super(e, t), this.storage = this.getStorage(), this._isUsingFakeStorage = !d();
147
+ class V extends E {
148
+ constructor(t = null, s = {}) {
149
+ super(t, s), this.storage = S, this._isUsingFakeStorage = !0;
149
150
  }
150
151
  getStorage() {
151
- return d() ? window.localStorage : h;
152
+ return y() ? window.localStorage : S;
152
153
  }
153
- setNamespace(e) {
154
+ setNamespace(t) {
154
155
  if (!this.namespace) {
155
- this.namespace = e;
156
+ this.namespace = t;
156
157
  return;
157
158
  }
158
- if (this.namespace === e)
159
- return;
160
- const t = JSON.parse(JSON.stringify(this.getAll()));
159
+ if (this.namespace === t) return;
160
+ const s = JSON.parse(JSON.stringify(this.getAll()));
161
161
  this.removeAll();
162
- for (const [r, o] of Object.entries(t)) {
163
- const n = r.replace(this.namespace, e);
164
- this.setItem(n, o);
162
+ for (const [r, n] of Object.entries(s)) {
163
+ const a = r.replace(this.namespace, t);
164
+ this.setItem(a, n);
165
165
  }
166
- this.namespace = e;
166
+ this.namespace = t;
167
167
  }
168
- getItem(e) {
169
- const t = this.storage.getItem(e);
170
- if (t == null)
171
- return null;
168
+ getItem(t) {
169
+ const s = this.storage.getItem(t);
170
+ if (s == null) return null;
172
171
  try {
173
- return JSON.parse(t);
172
+ return JSON.parse(s);
174
173
  } catch {
175
- return t;
174
+ return s;
176
175
  }
177
176
  }
178
- setItem(e, t) {
179
- let r = t;
180
- return r != null && (r = A(t) ? t : JSON.stringify(t)), this.storage.setItem(e, r);
177
+ setItem(t, s) {
178
+ let r = s;
179
+ return r != null && (r = G(s) ? s : JSON.stringify(s)), this.storage.setItem(t, r);
181
180
  }
182
- removeItem(e, t = !1) {
183
- return t && delete this.registry[e], this.storage.removeItem(e);
181
+ removeItem(t, s = !1) {
182
+ return s && delete this.registry[t], this.storage.removeItem(t);
184
183
  }
185
184
  getAll() {
186
- const e = `${this.namespace}.`;
187
- return Object.keys(this.storage).reduce((t, r) => ((!this.namespace || r.startsWith(e)) && (t[r] = this.storage.getItem(r)), t), {});
185
+ const t = `${this.namespace}.`;
186
+ return Object.keys(this.storage).reduce((s, r) => ((!this.namespace || r.startsWith(t)) && (s[r] = this.storage.getItem(r)), s), {});
188
187
  }
189
- _resetAll(e = !0, t = [], r = !1) {
190
- const o = `${this.namespace}.`;
191
- Object.keys(this.storage).forEach((n) => {
192
- const a = this.namespace ? n.startsWith(o) : !0, l = t?.includes(n) || !1;
193
- !a || l || (e ? Object.prototype.hasOwnProperty.call(this.registry, n) ? this.storage.setItem(n, this.registry[n]) : this.storage.removeItem(n) : (this.storage.removeItem(n), r && delete this.registry[n]));
188
+ _resetAll(t = !0, s = [], r = !1) {
189
+ const n = `${this.namespace}.`;
190
+ Object.keys(this.storage).forEach((a) => {
191
+ const c = this.namespace ? a.startsWith(n) : !0, _ = s?.includes(a) || !1;
192
+ !c || _ || (t ? Object.hasOwn(this.registry, a) ? this.storage.setItem(a, this.registry[a]) : this.storage.removeItem(a) : (this.storage.removeItem(a), r && delete this.registry[a]));
194
193
  });
195
194
  }
196
- resetAll(e = [], t = !1) {
197
- this._resetAll(!0, e || [], t);
195
+ resetAll(t = [], s = !1) {
196
+ this._resetAll(!0, t || [], s);
198
197
  }
199
- removeAll(e = [], t = !1) {
200
- this._resetAll(!1, e || [], t);
198
+ removeAll(t = [], s = !1) {
199
+ this._resetAll(!1, t || [], s);
201
200
  }
202
201
  /**
203
202
  * Attempt to upgrade from fake storage to real localStorage
204
203
  * This is useful for hydration scenarios
205
204
  */
206
205
  upgradeToRealStorage() {
207
- if (!this._isUsingFakeStorage || !d())
208
- return !1;
209
- const e = { ...this.storage };
210
- return this.storage = window.localStorage, this._isUsingFakeStorage = !1, Object.keys(e).forEach((t) => {
211
- if (t !== "__IS_FAKE_LOCAL_STORAGE__" && e[t] != null)
212
- try {
213
- this.storage.setItem(t, e[t]);
214
- } catch {
215
- return this.storage = h, this._isUsingFakeStorage = !0, !1;
216
- }
217
- }), !0;
206
+ return !this._isUsingFakeStorage || !y() ? !1 : (this.storage = window.localStorage, this._isUsingFakeStorage = !1, !0);
218
207
  }
219
208
  /**
220
209
  * Check if currently using fake storage
@@ -223,87 +212,135 @@ class T extends I {
223
212
  return this._isUsingFakeStorage;
224
213
  }
225
214
  }
226
- const L = {
215
+ const l = Math.random().toString(36).substring(7), i = (...e) => {
216
+ typeof globalThis < "u" && globalThis.__RWP_LOGGING_ENABLED__ !== !1 && console.log(...e);
217
+ }, v = {
227
218
  logging: {
228
219
  enabled: !1
229
220
  }
230
221
  };
231
- let v = T, i = new v(), u = { ...L }, f = [];
232
- const P = () => i.namespace, V = () => i, $ = () => u, C = (s) => {
233
- i.setNamespace(s), i = new v(s || P());
234
- }, H = (s) => {
235
- if (u = {
236
- ...u,
237
- ...s
238
- }, u.logging.enabled)
239
- for (console.info("Flushing", f.length, "pending logs"); f.length; )
240
- console.log(...f.shift());
241
- }, K = () => {
242
- if (!m())
243
- return !1;
244
- const s = i.upgradeToRealStorage();
245
- return s && E("react-wire-persisted: Upgraded to real localStorage after hydration"), s;
246
- }, E = (...s) => {
247
- u.logging.enabled ? console.log(...s) : f.push(s);
248
- }, W = (s, e = null) => {
249
- if (!s && typeof s != "number") throw new Error(
250
- `createPersistedWire: Key cannot be a falsey value (${s}}`
251
- );
252
- i.register(s, e);
253
- const t = U(e), r = () => t.getValue(), o = (c) => (i.setItem(s, c), t.setValue(c)), n = (c) => {
254
- t.subscribe(c);
255
- }, a = i.getItem(s), l = a === null ? e : a;
256
- return E("react-wire-persisted: create", s, {
257
- value: e,
258
- storedValue: a,
259
- initialValue: l
260
- }), l !== e && o(l), {
261
- ...t,
222
+ typeof globalThis < "u" && globalThis.__RWP_LOGGING_ENABLED__ === void 0 && (globalThis.__RWP_LOGGING_ENABLED__ = v.logging.enabled);
223
+ i("[RWP] Module initialized, instance ID:", l);
224
+ const W = V;
225
+ i("[RWP] About to check global storage, instanceId:", l);
226
+ let o;
227
+ try {
228
+ globalThis.__RWP_STORAGE__ ? i("[RWP] Using existing global storage in instance:", l) : (i("[RWP] Creating global storage in instance:", l), globalThis.__RWP_STORAGE__ = new W()), o = globalThis.__RWP_STORAGE__, i("[RWP] Storage assigned successfully");
229
+ } catch (e) {
230
+ globalThis.__RWP_LOGGING_ENABLED__ && console.error("[RWP] Error setting up global storage:", e), o = new W();
231
+ }
232
+ let h = { ...v };
233
+ const m = [];
234
+ typeof globalThis < "u" && (globalThis.__RWP_REGISTERED_WIRES__ ? i("[RWP] Using existing global registeredWires in instance:", l) : (i("[RWP] Creating global registeredWires in instance:", l), globalThis.__RWP_REGISTERED_WIRES__ = /* @__PURE__ */ new Map()));
235
+ const g = globalThis.__RWP_REGISTERED_WIRES__ || /* @__PURE__ */ new Map();
236
+ i("[RWP] registeredWires Map reference in instance:", l, "size:", g.size);
237
+ const j = () => o.namespace, M = () => o, $ = () => h, B = (e) => {
238
+ i("[RWP] setNamespace() called with:", e, "registered wires before:", g.size), o.setNamespace(e), o = new W(e || j()), i("[RWP] setNamespace() done, registered wires after:", g.size);
239
+ }, J = (e) => {
240
+ if (h = {
241
+ ...h,
242
+ ...e
243
+ }, typeof globalThis < "u" && (globalThis.__RWP_LOGGING_ENABLED__ = h.logging.enabled), h.logging.enabled)
244
+ for (console.info("Flushing", m.length, "pending logs"); m.length; )
245
+ console.log(...m.shift());
246
+ }, C = () => {
247
+ i("[RWP] refreshAllWires() called in instance:", l, "registered wires:", g.size), f("react-wire-persisted: refreshAllWires() called, registered wires:", g.size), g.forEach((e, t) => {
248
+ const s = o.getItem(t), r = e.getValue();
249
+ i("[RWP] Checking wire", t, {
250
+ storedValue: s,
251
+ currentValue: r,
252
+ willUpdate: s !== null && s !== r
253
+ }), f("react-wire-persisted: Checking wire", t, {
254
+ storedValue: s,
255
+ currentValue: r,
256
+ willUpdate: s !== null && s !== r
257
+ }), s !== null && s !== r && (i("[RWP] Refreshing wire", t, "with stored value", s), f("react-wire-persisted: Refreshing wire", t, "with stored value", s), e.setValue(s));
258
+ });
259
+ }, L = () => {
260
+ if (i("[RWP] upgradeStorage() called in instance:", l, {
261
+ isClient: u(),
262
+ isUsingFakeStorage: o.isUsingFakeStorage()
263
+ }), f("react-wire-persisted: upgradeStorage() called", {
264
+ isClient: u(),
265
+ isUsingFakeStorage: o.isUsingFakeStorage()
266
+ }), !u()) return !1;
267
+ const e = o.upgradeToRealStorage();
268
+ return i("[RWP] upgradeToRealStorage() returned", e), f("react-wire-persisted: upgradeToRealStorage() returned", e), e && (U(), i("[RWP] Upgraded to real localStorage, calling refreshAllWires()"), f("react-wire-persisted: Upgraded to real localStorage after hydration"), C()), e;
269
+ }, f = (...e) => {
270
+ h.logging.enabled ? console.log(...e) : m.push(e);
271
+ }, q = (e, t = null) => {
272
+ if (i("[RWP] createPersistedWire() called in instance:", l, "key:", e, "value:", t), !e && typeof e != "number") throw new Error(`createPersistedWire: Key cannot be a falsey value (${e}}`);
273
+ o.register(e, t);
274
+ const s = k(t), r = () => s.getValue(), n = (d) => (i(
275
+ "[RWP] setValue called in instance:",
276
+ l,
277
+ "key:",
278
+ e,
279
+ "isUsingFakeStorage:",
280
+ o.isUsingFakeStorage()
281
+ ), o.setItem(e, d), s.setValue(d)), a = (d) => {
282
+ s.subscribe(d);
283
+ };
284
+ let c = t;
285
+ const _ = b() || !o.isUsingFakeStorage();
286
+ if (_ && u()) {
287
+ const d = o.getItem(e);
288
+ d !== null && (c = d);
289
+ }
290
+ return f("react-wire-persisted: create", e, {
291
+ value: t,
292
+ initialValue: c,
293
+ hasHydratedStorage: b(),
294
+ isUsingFakeStorage: o.isUsingFakeStorage(),
295
+ canReadStorage: _
296
+ }), c !== t && n(c), g.set(e, {
297
+ getValue: r,
298
+ setValue: n,
299
+ subscribe: a
300
+ }), i("[RWP] Wire registered, total wires:", g.size, "keys:", Array.from(g.keys())), {
301
+ ...s,
262
302
  getValue: r,
263
- setValue: o,
264
- subscribe: n
303
+ setValue: n,
304
+ subscribe: a
265
305
  };
266
- }, J = (s = {}) => {
267
- const {
268
- autoUpgrade: e = !0,
269
- onUpgrade: t
270
- } = s, r = b(!1);
271
- return O(() => {
272
- if (!e || r.current || !m())
306
+ };
307
+ function Q({ children: e, onUpgrade: t, autoUpgrade: s = !0 }) {
308
+ const r = A(!1);
309
+ return T(() => {
310
+ if (!s || r.current || !u())
273
311
  return;
274
- const o = () => {
275
- _() && !r.current && K() && (r.current = !0, t?.());
312
+ const n = () => {
313
+ I() && !r.current && L() && (r.current = !0, t?.());
314
+ };
315
+ n();
316
+ const a = setTimeout(n, 0);
317
+ return () => clearTimeout(a);
318
+ }, [s, t]), e;
319
+ }
320
+ const X = (e = {}) => {
321
+ const { autoUpgrade: t = !0, onUpgrade: s } = e, r = A(!1);
322
+ return T(() => {
323
+ if (!t || r.current || !u()) return;
324
+ const n = () => {
325
+ I() && !r.current && L() && (r.current = !0, s?.());
276
326
  };
277
- o();
278
- const n = setTimeout(o, 0);
279
- return () => clearTimeout(n);
280
- }, [e, t]), {
327
+ n();
328
+ const a = setTimeout(n, 0);
329
+ return () => clearTimeout(a);
330
+ }, [t, s]), {
281
331
  hasUpgraded: r.current
282
332
  };
283
333
  };
284
- function D({ children: s, onUpgrade: e, autoUpgrade: t = !0 }) {
285
- const r = b(!1);
286
- return O(() => {
287
- if (!t || r.current || !m())
288
- return;
289
- const o = () => {
290
- _() && !r.current && K() && (r.current = !0, e?.());
291
- };
292
- o();
293
- const n = setTimeout(o, 0);
294
- return () => clearTimeout(n);
295
- }, [t, e]), s;
296
- }
297
334
  export {
298
- D as HydrationProvider,
299
- W as createPersistedWire,
300
- L as defaultOptions,
301
- P as getNamespace,
335
+ Q as HydrationProvider,
336
+ q as createPersistedWire,
337
+ v as defaultOptions,
338
+ j as getNamespace,
302
339
  $ as getOptions,
303
- V as getStorage,
304
- C as setNamespace,
305
- H as setOptions,
306
- K as upgradeStorage,
307
- J as useHydration,
308
- k as utils
340
+ M as getStorage,
341
+ B as setNamespace,
342
+ J as setOptions,
343
+ L as upgradeStorage,
344
+ X as useHydration,
345
+ z as utils
309
346
  };