dotmem 0.0.7 → 0.0.9

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/agent.js CHANGED
@@ -1,5 +1,4 @@
1
- import 'memorio/global';
2
- import { store, state, session, idb, hlc, dispatch, PROD, DEV } from 'memorio';
1
+ import { store, state, session, hlc, dispatch } from 'memorio';
3
2
 
4
3
  var __defProp = Object.defineProperty;
5
4
  var __getOwnPropNames = Object.getOwnPropertyNames;
@@ -17,11 +16,23 @@ var __export = (target, all) => {
17
16
  __defProp(target, name, { get: all[name], enumerable: true });
18
17
  };
19
18
 
19
+ // core/idb.ts
20
+ var idb;
21
+ var init_idb = __esm({
22
+ "core/idb.ts"() {
23
+ idb = {
24
+ db: {},
25
+ table: {},
26
+ data: {},
27
+ _disabled: true,
28
+ _warning: "IndexedDB is not available in this environment. Use dotmem store or session for persistence."
29
+ };
30
+ }
31
+ });
32
+
20
33
  // core/global.ts
21
34
  var global_exports = {};
22
35
  __export(global_exports, {
23
- DEV: () => DEV,
24
- PROD: () => PROD,
25
36
  dispatch: () => dispatch,
26
37
  getPlatform: () => getPlatform,
27
38
  hlc: () => hlc,
@@ -33,6 +44,7 @@ __export(global_exports, {
33
44
  var getPlatform;
34
45
  var init_global = __esm({
35
46
  "core/global.ts"() {
47
+ init_idb();
36
48
  getPlatform = /* @__PURE__ */ __name(() => {
37
49
  const proc = globalThis.process;
38
50
  if (proc) {