@livestore/react 0.4.0-dev.2 → 0.4.0-dev.21

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 (96) hide show
  1. package/dist/.tsbuildinfo +1 -1
  2. package/dist/LiveStoreContext.d.ts +27 -0
  3. package/dist/LiveStoreContext.d.ts.map +1 -1
  4. package/dist/LiveStoreContext.js +18 -0
  5. package/dist/LiveStoreContext.js.map +1 -1
  6. package/dist/LiveStoreProvider.d.ts +14 -8
  7. package/dist/LiveStoreProvider.d.ts.map +1 -1
  8. package/dist/LiveStoreProvider.js +40 -24
  9. package/dist/LiveStoreProvider.js.map +1 -1
  10. package/dist/LiveStoreProvider.test.js +7 -7
  11. package/dist/LiveStoreProvider.test.js.map +1 -1
  12. package/dist/__tests__/fixture.d.ts +34 -12
  13. package/dist/__tests__/fixture.d.ts.map +1 -1
  14. package/dist/__tests__/fixture.js +13 -5
  15. package/dist/__tests__/fixture.js.map +1 -1
  16. package/dist/experimental/components/LiveList.js +1 -1
  17. package/dist/experimental/mod.d.ts +1 -0
  18. package/dist/experimental/mod.d.ts.map +1 -1
  19. package/dist/experimental/mod.js +1 -0
  20. package/dist/experimental/mod.js.map +1 -1
  21. package/dist/experimental/multi-store/StoreRegistry.d.ts +105 -0
  22. package/dist/experimental/multi-store/StoreRegistry.d.ts.map +1 -0
  23. package/dist/experimental/multi-store/StoreRegistry.js +184 -0
  24. package/dist/experimental/multi-store/StoreRegistry.js.map +1 -0
  25. package/dist/experimental/multi-store/StoreRegistry.test.d.ts +2 -0
  26. package/dist/experimental/multi-store/StoreRegistry.test.d.ts.map +1 -0
  27. package/dist/experimental/multi-store/StoreRegistry.test.js +381 -0
  28. package/dist/experimental/multi-store/StoreRegistry.test.js.map +1 -0
  29. package/dist/experimental/multi-store/StoreRegistryContext.d.ts +10 -0
  30. package/dist/experimental/multi-store/StoreRegistryContext.d.ts.map +1 -0
  31. package/dist/experimental/multi-store/StoreRegistryContext.js +15 -0
  32. package/dist/experimental/multi-store/StoreRegistryContext.js.map +1 -0
  33. package/dist/experimental/multi-store/mod.d.ts +6 -0
  34. package/dist/experimental/multi-store/mod.d.ts.map +1 -0
  35. package/dist/experimental/multi-store/mod.js +6 -0
  36. package/dist/experimental/multi-store/mod.js.map +1 -0
  37. package/dist/experimental/multi-store/storeOptions.d.ts +4 -0
  38. package/dist/experimental/multi-store/storeOptions.d.ts.map +1 -0
  39. package/dist/experimental/multi-store/storeOptions.js +4 -0
  40. package/dist/experimental/multi-store/storeOptions.js.map +1 -0
  41. package/dist/experimental/multi-store/types.d.ts +25 -0
  42. package/dist/experimental/multi-store/types.d.ts.map +1 -0
  43. package/dist/experimental/multi-store/types.js +2 -0
  44. package/dist/experimental/multi-store/types.js.map +1 -0
  45. package/dist/experimental/multi-store/useStore.d.ts +11 -0
  46. package/dist/experimental/multi-store/useStore.d.ts.map +1 -0
  47. package/dist/experimental/multi-store/useStore.js +16 -0
  48. package/dist/experimental/multi-store/useStore.js.map +1 -0
  49. package/dist/experimental/multi-store/useStore.test.d.ts +2 -0
  50. package/dist/experimental/multi-store/useStore.test.d.ts.map +1 -0
  51. package/dist/experimental/multi-store/useStore.test.js +198 -0
  52. package/dist/experimental/multi-store/useStore.test.js.map +1 -0
  53. package/dist/mod.d.ts +1 -1
  54. package/dist/mod.d.ts.map +1 -1
  55. package/dist/mod.js.map +1 -1
  56. package/dist/useClientDocument.d.ts +43 -13
  57. package/dist/useClientDocument.d.ts.map +1 -1
  58. package/dist/useClientDocument.js +4 -5
  59. package/dist/useClientDocument.js.map +1 -1
  60. package/dist/useClientDocument.test.js +29 -7
  61. package/dist/useClientDocument.test.js.map +1 -1
  62. package/dist/useQuery.d.ts +28 -6
  63. package/dist/useQuery.d.ts.map +1 -1
  64. package/dist/useQuery.js +63 -18
  65. package/dist/useQuery.js.map +1 -1
  66. package/dist/useQuery.test.js +35 -11
  67. package/dist/useQuery.test.js.map +1 -1
  68. package/dist/useRcResource.test.js +1 -1
  69. package/dist/useStore.d.ts +53 -1
  70. package/dist/useStore.d.ts.map +1 -1
  71. package/dist/useStore.js +52 -1
  72. package/dist/useStore.js.map +1 -1
  73. package/package.json +14 -14
  74. package/src/LiveStoreContext.ts +27 -0
  75. package/src/LiveStoreProvider.test.tsx +7 -7
  76. package/src/LiveStoreProvider.tsx +67 -45
  77. package/src/__snapshots__/useClientDocument.test.tsx.snap +208 -100
  78. package/src/__snapshots__/useQuery.test.tsx.snap +400 -128
  79. package/src/__tests__/fixture.tsx +23 -24
  80. package/src/experimental/components/LiveList.tsx +1 -1
  81. package/src/experimental/mod.ts +1 -0
  82. package/src/experimental/multi-store/StoreRegistry.test.ts +518 -0
  83. package/src/experimental/multi-store/StoreRegistry.ts +253 -0
  84. package/src/experimental/multi-store/StoreRegistryContext.tsx +23 -0
  85. package/src/experimental/multi-store/mod.ts +5 -0
  86. package/src/experimental/multi-store/storeOptions.ts +8 -0
  87. package/src/experimental/multi-store/types.ts +37 -0
  88. package/src/experimental/multi-store/useStore.test.tsx +269 -0
  89. package/src/experimental/multi-store/useStore.ts +26 -0
  90. package/src/mod.ts +2 -1
  91. package/src/useClientDocument.test.tsx +105 -75
  92. package/src/useClientDocument.ts +58 -13
  93. package/src/useQuery.test.tsx +62 -11
  94. package/src/useQuery.ts +98 -27
  95. package/src/useRcResource.test.tsx +1 -1
  96. package/src/useStore.ts +55 -3
@@ -1 +1 @@
1
- {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../src/experimental/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,KAAK,aAAa,EAAE,MAAM,2BAA2B,CAAA"}
1
+ {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../../src/experimental/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,KAAK,aAAa,EAAE,MAAM,2BAA2B,CAAA;AACxE,cAAc,sBAAsB,CAAA"}
@@ -1,2 +1,3 @@
1
1
  export { LiveList } from "./components/LiveList.js";
2
+ export * from "./multi-store/mod.js";
2
3
  //# sourceMappingURL=mod.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"mod.js","sourceRoot":"","sources":["../../src/experimental/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAsB,MAAM,0BAA2B,CAAA"}
1
+ {"version":3,"file":"mod.js","sourceRoot":"","sources":["../../src/experimental/mod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAsB,MAAM,0BAA2B,CAAA;AACxE,cAAc,sBAAsB,CAAA"}
@@ -0,0 +1,105 @@
1
+ import { UnknownError } from '@livestore/common';
2
+ import type { LiveStoreSchema } from '@livestore/common/schema';
3
+ import { type Store } from '@livestore/livestore';
4
+ import { Effect, type OtelTracer, Runtime, type Scope } from '@livestore/utils/effect';
5
+ import type { CachedStoreOptions } from './types.ts';
6
+ type DefaultStoreOptions = Partial<Pick<CachedStoreOptions, 'batchUpdates' | 'disableDevtools' | 'confirmUnsavedChanges' | 'syncPayload' | 'debug' | 'otelOptions'>> & {
7
+ /**
8
+ * The time in milliseconds that unused stores remain in memory.
9
+ * When a store becomes unused (no active retentions), it will be disposed
10
+ * after this duration.
11
+ *
12
+ * Stores transition to the unused state as soon as they have no
13
+ * active retentions, so when all components which use that store
14
+ * have unmounted.
15
+ *
16
+ * @remarks
17
+ * - If set to `Infinity`, will disable disposal
18
+ * - The maximum allowed time is about {@link https://developer.mozilla.org/en-US/docs/Web/API/Window/setTimeout#maximum_delay_value | 24 days}
19
+ *
20
+ * @defaultValue `60_000` (60 seconds) or `Infinity` during SSR to avoid
21
+ * disposing stores before server render completes.
22
+ */
23
+ unusedCacheTime?: number;
24
+ /**
25
+ * Optionally, pass a custom runtime that will be used to run all operations (loading, caching, etc.).
26
+ */
27
+ runtime?: Runtime.Runtime<Scope.Scope | OtelTracer.OtelTracer>;
28
+ };
29
+ /**
30
+ * Store Registry coordinating store loading, caching, and retention
31
+ *
32
+ * @public
33
+ */
34
+ export declare class StoreRegistry {
35
+ #private;
36
+ /**
37
+ * Creates a new StoreRegistry instance.
38
+ *
39
+ * @param params.defaultOptions - Default options applied to all stores managed by this registry when they are loaded.
40
+ *
41
+ * @example
42
+ * ```ts
43
+ * const registry = new StoreRegistry({
44
+ * defaultOptions: {
45
+ * batchUpdates,
46
+ * unusedCacheTime: 30_000,
47
+ * }
48
+ * })
49
+ * ```
50
+ */
51
+ constructor(params?: {
52
+ defaultOptions?: DefaultStoreOptions;
53
+ });
54
+ /**
55
+ * Gets a cached store or loads a new one, with the store lifetime scoped to the caller.
56
+ *
57
+ * @typeParam TSchema - The schema type for the store
58
+ * @returns An Effect that yields the store, scoped to the provided Scope
59
+ *
60
+ * @remarks
61
+ * - Stores are kept in cache and reused while any scope holds them
62
+ * - When the scope closes, the reference is released; the store is disposed after `unusedCacheTime`
63
+ * if no other scopes retain it
64
+ * - Concurrent calls with the same storeId share the same store instance
65
+ */
66
+ getOrLoad: <TSchema extends LiveStoreSchema>(options: CachedStoreOptions<TSchema>) => Effect.Effect<Store<TSchema>, UnknownError, Scope.Scope>;
67
+ /**
68
+ * Get or load a store, returning it directly if already loaded or a promise if loading.
69
+ *
70
+ * @typeParam TSchema - The schema type for the store
71
+ * @returns The loaded store if available, or a Promise that resolves to the loaded store
72
+ * @throws unknown loading error
73
+ *
74
+ * @remarks
75
+ * - Returns the store instance directly (synchronous) when already loaded
76
+ * - Returns a stable Promise reference when loading is in progress or needs to be initiated
77
+ * - Throws with the same error instance on subsequent calls after failure
78
+ * - Applies default options from registry config, with call-site options taking precedence
79
+ * - Concurrent calls with the same storeId share the same store instance
80
+ */
81
+ getOrLoadPromise: <TSchema extends LiveStoreSchema>(options: CachedStoreOptions<TSchema>) => Store<TSchema> | Promise<Store<TSchema>>;
82
+ /**
83
+ * Retains the store in cache until the returned release function is called.
84
+ *
85
+ * @returns A release function that, when called, removes this retention hold
86
+ *
87
+ * @remarks
88
+ * - Multiple retains on the same store are independent; each must be released separately
89
+ * - If the store isn't cached yet, it will be loaded and then retained
90
+ */
91
+ retain: (options: CachedStoreOptions<any>) => (() => void);
92
+ /**
93
+ * Warms the cache for a store without adding a retention.
94
+ *
95
+ * @typeParam TSchema - The schema of the store to preload
96
+ * @returns A promise that resolves when the loading is complete (success or failure)
97
+ *
98
+ * @remarks
99
+ * - We don't return the store or throw as this is a fire-and-forget operation.
100
+ * - If the entry remains unused after preload resolves/rejects, it is scheduled for disposal.
101
+ */
102
+ preload: <TSchema extends LiveStoreSchema>(options: CachedStoreOptions<TSchema>) => Promise<void>;
103
+ }
104
+ export {};
105
+ //# sourceMappingURL=StoreRegistry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"StoreRegistry.d.ts","sourceRoot":"","sources":["../../../src/experimental/multi-store/StoreRegistry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAC/D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAA;AAC/D,OAAO,EAAe,KAAK,KAAK,EAAE,MAAM,sBAAsB,CAAA;AAC9D,OAAO,EAEL,MAAM,EAON,KAAK,UAAU,EAEf,OAAO,EACP,KAAK,KAAK,EACX,MAAM,yBAAyB,CAAA;AAChC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAA;AAYpD,KAAK,mBAAmB,GAAG,OAAO,CAChC,IAAI,CACF,kBAAkB,EAClB,cAAc,GAAG,iBAAiB,GAAG,uBAAuB,GAAG,aAAa,GAAG,OAAO,GAAG,aAAa,CACvG,CACF,GAAG;IACF;;;;;;;;;;;;;;;OAeG;IACH,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,KAAK,GAAG,UAAU,CAAC,UAAU,CAAC,CAAA;CAC/D,CAAA;AAkCD;;;;GAIG;AACH,qBAAa,aAAa;;IAmBxB;;;;;;;;;;;;;;OAcG;gBACS,MAAM,GAAE;QAAE,cAAc,CAAC,EAAE,mBAAmB,CAAA;KAAO;IAkBjE;;;;;;;;;;;OAWG;IACH,SAAS,GAAI,OAAO,SAAS,eAAe,EAC1C,SAAS,kBAAkB,CAAC,OAAO,CAAC,KACnC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,EAAE,YAAY,EAAE,KAAK,CAAC,KAAK,CAAC,CAMa;IAExE;;;;;;;;;;;;;OAaG;IACH,gBAAgB,GAAI,OAAO,SAAS,eAAe,EACjD,SAAS,kBAAkB,CAAC,OAAO,CAAC,KACnC,KAAK,CAAC,OAAO,CAAC,GAAG,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CA0B1C;IAED;;;;;;;;OAQG;IACH,MAAM,GAAI,SAAS,kBAAkB,CAAC,GAAG,CAAC,KAAG,CAAC,MAAM,IAAI,CAAC,CAWxD;IAED;;;;;;;;;OASG;IACH,OAAO,GAAU,OAAO,SAAS,eAAe,EAAE,SAAS,kBAAkB,CAAC,OAAO,CAAC,KAAG,OAAO,CAAC,IAAI,CAAC,CAMrG;CACF"}
@@ -0,0 +1,184 @@
1
+ import { OtelLiveDummy, UnknownError } from '@livestore/common';
2
+ import { createStore } from '@livestore/livestore';
3
+ import { Cause, Effect, Equal, Exit, Fiber, Hash, Layer, ManagedRuntime, RcMap, Runtime, } from '@livestore/utils/effect';
4
+ /**
5
+ * Default time to keep unused stores in cache.
6
+ *
7
+ * - Browser: 60 seconds (60,000ms)
8
+ * - SSR: Infinity (disables disposal to avoid disposing stores before server render completes)
9
+ *
10
+ * @internal Exported primarily for testing purposes.
11
+ */
12
+ export const DEFAULT_UNUSED_CACHE_TIME = typeof window === 'undefined' ? Number.POSITIVE_INFINITY : 60_000;
13
+ /**
14
+ * RcMap cache key that uses storeId for equality/hashing but carries full options.
15
+ * This allows RcMap to deduplicate by storeId while the lookup function has access to all options.
16
+ *
17
+ * @remarks
18
+ * Only `storeId` is used for equality and hashing. This means if `getOrLoadPromise` is called
19
+ * with different options (e.g., different `adapter`) but the same `storeId`, the cached store
20
+ * from the first call will be returned. This is intentional - a store's identity is determined
21
+ * solely by its `storeId`, and callers should not expect to get different stores by varying
22
+ * other options while keeping the same `storeId`.
23
+ */
24
+ class StoreCacheKey {
25
+ options;
26
+ constructor(options) {
27
+ this.options = options;
28
+ }
29
+ /**
30
+ * Equality is based solely on `storeId`. Other options in `CachedStoreOptions` are ignored
31
+ * for cache key comparison. The first options used for a given `storeId` determine the
32
+ * store's configuration.
33
+ */
34
+ [Equal.symbol](that) {
35
+ return that instanceof StoreCacheKey && this.options.storeId === that.options.storeId;
36
+ }
37
+ [Hash.symbol]() {
38
+ return Hash.string(this.options.storeId);
39
+ }
40
+ }
41
+ /**
42
+ * Store Registry coordinating store loading, caching, and retention
43
+ *
44
+ * @public
45
+ */
46
+ export class StoreRegistry {
47
+ /**
48
+ * Reference-counted cache mapping storeId to Store instances.
49
+ * Stores are created on first access and disposed after `unusedCacheTime` when all references are released.
50
+ */
51
+ #rcMap;
52
+ /**
53
+ * Effect runtime providing Scope and OtelTracer for all registry operations.
54
+ * When the runtime's scope closes, all managed stores are automatically shut down.
55
+ */
56
+ #runtime;
57
+ /**
58
+ * In-flight loading promises keyed by storeId.
59
+ * Ensures concurrent `getOrLoadPromise` calls receive the same Promise reference.
60
+ */
61
+ #loadingPromises = new Map();
62
+ /**
63
+ * Creates a new StoreRegistry instance.
64
+ *
65
+ * @param params.defaultOptions - Default options applied to all stores managed by this registry when they are loaded.
66
+ *
67
+ * @example
68
+ * ```ts
69
+ * const registry = new StoreRegistry({
70
+ * defaultOptions: {
71
+ * batchUpdates,
72
+ * unusedCacheTime: 30_000,
73
+ * }
74
+ * })
75
+ * ```
76
+ */
77
+ constructor(params = {}) {
78
+ this.#runtime =
79
+ params.defaultOptions?.runtime ??
80
+ ManagedRuntime.make(Layer.mergeAll(Layer.scope, OtelLiveDummy)).runtimeEffect.pipe(Effect.runSync);
81
+ this.#rcMap = RcMap.make({
82
+ lookup: (key) => Effect.gen(this, function* () {
83
+ const { options } = key;
84
+ return yield* createStore(options).pipe(Effect.catchAllDefect((cause) => UnknownError.make({ cause })));
85
+ }).pipe(Effect.withSpan(`StoreRegistry.lookup:${key.options.storeId}`)),
86
+ // TODO: Make idleTimeToLive vary for each store when Effect supports per-resource TTL
87
+ // See https://github.com/livestorejs/livestore/issues/917
88
+ idleTimeToLive: params.defaultOptions?.unusedCacheTime ?? DEFAULT_UNUSED_CACHE_TIME,
89
+ }).pipe(Runtime.runSync(this.#runtime));
90
+ }
91
+ /**
92
+ * Gets a cached store or loads a new one, with the store lifetime scoped to the caller.
93
+ *
94
+ * @typeParam TSchema - The schema type for the store
95
+ * @returns An Effect that yields the store, scoped to the provided Scope
96
+ *
97
+ * @remarks
98
+ * - Stores are kept in cache and reused while any scope holds them
99
+ * - When the scope closes, the reference is released; the store is disposed after `unusedCacheTime`
100
+ * if no other scopes retain it
101
+ * - Concurrent calls with the same storeId share the same store instance
102
+ */
103
+ getOrLoad = (options) => Effect.gen(this, function* () {
104
+ const key = new StoreCacheKey(options);
105
+ const store = yield* RcMap.get(this.#rcMap, key);
106
+ return store;
107
+ }).pipe(Effect.withSpan(`StoreRegistry.getOrLoad:${options.storeId}`));
108
+ /**
109
+ * Get or load a store, returning it directly if already loaded or a promise if loading.
110
+ *
111
+ * @typeParam TSchema - The schema type for the store
112
+ * @returns The loaded store if available, or a Promise that resolves to the loaded store
113
+ * @throws unknown loading error
114
+ *
115
+ * @remarks
116
+ * - Returns the store instance directly (synchronous) when already loaded
117
+ * - Returns a stable Promise reference when loading is in progress or needs to be initiated
118
+ * - Throws with the same error instance on subsequent calls after failure
119
+ * - Applies default options from registry config, with call-site options taking precedence
120
+ * - Concurrent calls with the same storeId share the same store instance
121
+ */
122
+ getOrLoadPromise = (options) => {
123
+ const exit = this.getOrLoad(options).pipe(Effect.scoped, Runtime.runSyncExit(this.#runtime));
124
+ if (Exit.isSuccess(exit))
125
+ return exit.value;
126
+ // Check if the failure is due to async work
127
+ const defect = Cause.dieOption(exit.cause);
128
+ if (defect._tag === 'Some' && Runtime.isAsyncFiberException(defect.value)) {
129
+ const { storeId } = options;
130
+ // Return cached promise if one exists (ensures concurrent calls get the same Promise reference)
131
+ const cached = this.#loadingPromises.get(storeId);
132
+ if (cached)
133
+ return cached;
134
+ // Create and cache the promise
135
+ const fiber = defect.value.fiber;
136
+ const promise = Fiber.join(fiber)
137
+ .pipe(Runtime.runPromise(this.#runtime))
138
+ .finally(() => this.#loadingPromises.delete(storeId));
139
+ this.#loadingPromises.set(storeId, promise);
140
+ return promise;
141
+ }
142
+ // Handle synchronous failure
143
+ throw Cause.squash(exit.cause);
144
+ };
145
+ /**
146
+ * Retains the store in cache until the returned release function is called.
147
+ *
148
+ * @returns A release function that, when called, removes this retention hold
149
+ *
150
+ * @remarks
151
+ * - Multiple retains on the same store are independent; each must be released separately
152
+ * - If the store isn't cached yet, it will be loaded and then retained
153
+ */
154
+ retain = (options) => {
155
+ const release = Effect.gen(this, function* () {
156
+ const key = new StoreCacheKey(options);
157
+ yield* RcMap.get(this.#rcMap, key);
158
+ // Effect.never suspends indefinitely, keeping the RcMap reference alive.
159
+ // When `release()` is called, the fiber is interrupted, closing the scope
160
+ // and releasing the RcMap entry (which may trigger disposal after idleTimeToLive).
161
+ yield* Effect.never;
162
+ }).pipe(Effect.scoped, Runtime.runCallback(this.#runtime));
163
+ return () => release();
164
+ };
165
+ /**
166
+ * Warms the cache for a store without adding a retention.
167
+ *
168
+ * @typeParam TSchema - The schema of the store to preload
169
+ * @returns A promise that resolves when the loading is complete (success or failure)
170
+ *
171
+ * @remarks
172
+ * - We don't return the store or throw as this is a fire-and-forget operation.
173
+ * - If the entry remains unused after preload resolves/rejects, it is scheduled for disposal.
174
+ */
175
+ preload = async (options) => {
176
+ try {
177
+ await this.getOrLoadPromise(options);
178
+ }
179
+ catch {
180
+ // Do nothing; preload is best-effort
181
+ }
182
+ };
183
+ }
184
+ //# sourceMappingURL=StoreRegistry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"StoreRegistry.js","sourceRoot":"","sources":["../../../src/experimental/multi-store/StoreRegistry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAE/D,OAAO,EAAE,WAAW,EAAc,MAAM,sBAAsB,CAAA;AAC9D,OAAO,EACL,KAAK,EACL,MAAM,EACN,KAAK,EACL,IAAI,EACJ,KAAK,EACL,IAAI,EACJ,KAAK,EACL,cAAc,EAEd,KAAK,EACL,OAAO,GAER,MAAM,yBAAyB,CAAA;AAGhC;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG,OAAO,MAAM,KAAK,WAAW,CAAC,CAAC,CAAC,MAAM,CAAC,iBAAiB,CAAC,CAAC,CAAC,MAAM,CAAA;AA+B1G;;;;;;;;;;GAUG;AACH,MAAM,aAAa;IACR,OAAO,CAA6B;IAE7C,YAAY,OAAoC;QAC9C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAA;IACxB,CAAC;IAED;;;;OAIG;IACH,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAiB;QAC9B,OAAO,IAAI,YAAY,aAAa,IAAI,IAAI,CAAC,OAAO,CAAC,OAAO,KAAK,IAAI,CAAC,OAAO,CAAC,OAAO,CAAA;IACvF,CAAC;IAED,CAAC,IAAI,CAAC,MAAM,CAAC;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAA;IAC1C,CAAC;CACF;AAED;;;;GAIG;AACH,MAAM,OAAO,aAAa;IACxB;;;OAGG;IACH,MAAM,CAAsD;IAE5D;;;OAGG;IACH,QAAQ,CAAsD;IAE9D;;;OAGG;IACH,gBAAgB,GAAqC,IAAI,GAAG,EAAE,CAAA;IAE9D;;;;;;;;;;;;;;OAcG;IACH,YAAY,SAAmD,EAAE;QAC/D,IAAI,CAA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,OAAO,CAAA;QAChB,CAAC;QAED,6BAA6B;QAC7B,MAAM,KAAK,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAA;IAChC,CAAC,CAAA;IAED;;;;;;;;OAQG;IACH,MAAM,GAAG,CAAC,OAAgC,EAAgB,EAAE;QAC1D,MAAM,OAAO,GAAG,MAAM,CAAC,GAAG,CAAC,IAAI,EAAE,QAAQ,CAAC;YACxC,MAAM,GAAG,GAAG,IAAI,aAAa,CAAC,OAAO,CAAC,CAAA;YACtC,KAAK,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;YAClC,yEAAyE;YACzE,0EAA0E;YAC1E,mFAAmF;YACnF,KAAK,CAAC,CAAC,MAAM,CAAC,KAAK,CAAA;QACrB,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAA;QAE1D,OAAO,GAAG,EAAE,CAAC,OAAO,EAAE,CAAA;IACxB,CAAC,CAAA;IAED;;;;;;;;;OASG;IACH,OAAO,GAAG,KAAK,EAAmC,OAAoC,EAAiB,EAAE;QACvG,IAAI,CAAC;YACH,MAAM,IAAI,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAA;QACtC,CAAC;QAAC,MAAM,CAAC;YACP,qCAAqC;QACvC,CAAC;IACH,CAAC,CAAA;CACF"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=StoreRegistry.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"StoreRegistry.test.d.ts","sourceRoot":"","sources":["../../../src/experimental/multi-store/StoreRegistry.test.ts"],"names":[],"mappings":""}