memorio 2.6.6 → 2.7.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/package.json CHANGED
@@ -1,10 +1,11 @@
1
1
  {
2
2
  "name": "memorio",
3
3
  "code": "memorio",
4
- "version": "2.6.6",
5
- "description": "Memorio, State + Observer, Store and iDB for an easy life",
4
+ "version": "2.7.0",
5
+ "description": "Memorio, State + Observer, Store and iDB for an easy life - Cross-platform compatible",
6
6
  "main": "./index.cjs",
7
7
  "browser": "./index.cjs",
8
+ "module": "./index.js",
8
9
  "types": "./index.d.ts",
9
10
  "typing": "./types/*",
10
11
  "homepage": "https://a51.gitbook.io/memorio",
@@ -22,15 +23,20 @@
22
23
  }
23
24
  ],
24
25
  "keywords": [
25
- "elements",
26
- "ui",
27
- "ux",
28
- "inputs",
29
- "buttons",
30
- "frontend",
31
- "gui",
32
- "styles",
33
- "customization"
26
+ "state",
27
+ "observer",
28
+ "store",
29
+ "session",
30
+ "cache",
31
+ "idb",
32
+ "indexeddb",
33
+ "reactive",
34
+ "universal",
35
+ "cross-platform",
36
+ "node",
37
+ "deno",
38
+ "browser",
39
+ "frontend"
34
40
  ],
35
41
  "funding": [
36
42
  {
@@ -67,7 +73,6 @@
67
73
  "optional": false
68
74
  }
69
75
  },
70
- "module": "./index.js",
71
76
  "exports": {
72
77
  ".": {
73
78
  "import": "./index.js",
@@ -25,6 +25,28 @@ interface _memorio {
25
25
  _tracking?: boolean
26
26
  _trackedPaths?: Set<string>
27
27
  _locked?: boolean
28
+ // Platform properties
29
+ _platform?: string
30
+ _capabilities?: any
31
+ _sessionId?: string
32
+ _currentContext?: string
33
+ // Context management (for server-side isolation)
34
+ createContext?: (name?: string) => {
35
+ id: string
36
+ state: any
37
+ store: any
38
+ session: any
39
+ cache: any
40
+ }
41
+ listContexts?: () => string[]
42
+ deleteContext?: (id: string) => boolean
43
+ isolate?: (name?: string) => {
44
+ id: string
45
+ state: any
46
+ store: any
47
+ session: any
48
+ cache: any
49
+ }
28
50
  }
29
51
 
30
52
  type memorio = _memorio
@@ -1,9 +1,4 @@
1
- /*!
2
- memorio
3
- Copyright (c) 2025 Dario Passariello <dariopassariello@gmail.com>
4
- Licensed under Private License, see
5
- https://dario.passariello.ca
6
- */
1
+
7
2
 
8
3
  /**
9
4
  * Create states using: session.set("example",{test:"test"})
@@ -94,6 +89,12 @@ interface _session {
94
89
  */
95
90
  list?: () => object
96
91
 
92
+ /**
93
+ * Check if using real persistent storage or fallback
94
+ * @since memorio 2.7.0
95
+ */
96
+ isPersistent?: boolean
97
+
97
98
  // TODO
98
99
  // readonly increaseQuota: (value: number) => void
99
100
  }
package/types/state.d.ts CHANGED
@@ -1,9 +1,4 @@
1
- /*!
2
- memorio
3
- Copyright (c) 2025 Dario Passariello <dariopassariello@gmail.com>
4
- Licensed under Private License, see
5
- https://dario.passariello.ca
6
- */
1
+
7
2
 
8
3
  /**
9
4
  * If you use only "state" you get the entire Proxy object
package/types/store.d.ts CHANGED
@@ -1,10 +1,3 @@
1
- /*!
2
- memorio
3
- Copyright (c) 2025 Dario Passariello <dariopassariello@gmail.com>
4
- Licensed under Private License, see
5
- https://dario.passariello.ca
6
- */
7
-
8
1
  /**
9
2
  * Create states using: store.set("example",{test:"test"})
10
3
  */
@@ -94,6 +87,12 @@ interface _store {
94
87
  */
95
88
  list?: () => object
96
89
 
90
+ /**
91
+ * Check if using real persistent storage or fallback
92
+ * @since memorio 2.7.0
93
+ */
94
+ isPersistent?: boolean
95
+
97
96
  // TODO
98
97
  // readonly increaseQuota: (value: number) => void
99
98
  }