@xhub-short/contracts 0.1.0-beta.14 → 0.1.0-beta.16

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.
Files changed (2) hide show
  1. package/dist/index.d.ts +12 -0
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -939,6 +939,18 @@ interface IStorage {
939
939
  * - Used for debugging and LRU eviction
940
940
  */
941
941
  keys(): Promise<string[]>;
942
+ /**
943
+ * Get a value from storage synchronously (optional)
944
+ *
945
+ * Used for zero-flash cache hydration during React render phase.
946
+ * Only implement if the underlying storage supports synchronous reads
947
+ * (e.g., localStorage). Async-only storage (e.g., IndexedDB) should
948
+ * not implement this.
949
+ *
950
+ * @param key - Storage key
951
+ * @returns The stored value or null if not found / not supported
952
+ */
953
+ getSync?<T>(key: string): T | null;
942
954
  }
943
955
  /**
944
956
  * Specialized interface for session snapshot storage
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@xhub-short/contracts",
3
3
  "sideEffects": false,
4
- "version": "0.1.0-beta.14",
4
+ "version": "0.1.0-beta.16",
5
5
  "type": "module",
6
6
  "publishConfig": {
7
7
  "access": "public"