@livestore/react 0.4.0-dev.0 → 0.4.0-dev.10
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/dist/.tsbuildinfo +1 -1
- package/dist/LiveStoreProvider.d.ts +1 -3
- package/dist/LiveStoreProvider.d.ts.map +1 -1
- package/dist/LiveStoreProvider.js +22 -18
- package/dist/LiveStoreProvider.js.map +1 -1
- package/dist/LiveStoreProvider.test.js +1 -1
- package/dist/LiveStoreProvider.test.js.map +1 -1
- package/dist/__tests__/fixture.d.ts +24 -3
- package/dist/__tests__/fixture.d.ts.map +1 -1
- package/dist/__tests__/fixture.js +10 -3
- package/dist/__tests__/fixture.js.map +1 -1
- package/dist/mod.d.ts +1 -1
- package/dist/mod.d.ts.map +1 -1
- package/dist/mod.js.map +1 -1
- package/dist/useClientDocument.d.ts +10 -13
- package/dist/useClientDocument.d.ts.map +1 -1
- package/dist/useClientDocument.js +3 -4
- package/dist/useClientDocument.js.map +1 -1
- package/dist/useClientDocument.test.js +20 -2
- package/dist/useClientDocument.test.js.map +1 -1
- package/dist/useQuery.d.ts.map +1 -1
- package/dist/useQuery.js +1 -2
- package/dist/useQuery.js.map +1 -1
- package/package.json +13 -13
- package/src/LiveStoreProvider.test.tsx +1 -1
- package/src/LiveStoreProvider.tsx +24 -19
- package/src/__snapshots__/useClientDocument.test.tsx.snap +208 -100
- package/src/__snapshots__/useQuery.test.tsx.snap +388 -116
- package/src/__tests__/fixture.tsx +17 -9
- package/src/mod.ts +2 -1
- package/src/useClientDocument.test.tsx +31 -2
- package/src/useClientDocument.ts +22 -12
- package/src/useQuery.ts +1 -2
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@livestore/react",
|
3
|
-
"version": "0.4.0-dev.
|
3
|
+
"version": "0.4.0-dev.10",
|
4
4
|
"type": "module",
|
5
5
|
"sideEffects": false,
|
6
6
|
"exports": {
|
@@ -9,25 +9,25 @@
|
|
9
9
|
},
|
10
10
|
"dependencies": {
|
11
11
|
"@opentelemetry/api": "1.9.0",
|
12
|
-
"@livestore/common": "0.4.0-dev.
|
13
|
-
"@livestore/livestore": "0.4.0-dev.
|
14
|
-
"@livestore/utils": "0.4.0-dev.
|
12
|
+
"@livestore/common": "0.4.0-dev.10",
|
13
|
+
"@livestore/livestore": "0.4.0-dev.10",
|
14
|
+
"@livestore/utils": "0.4.0-dev.10"
|
15
15
|
},
|
16
16
|
"devDependencies": {
|
17
17
|
"@opentelemetry/sdk-trace-base": "^2.0.1",
|
18
18
|
"@testing-library/dom": "^10.4.1",
|
19
19
|
"@testing-library/react": "^16.3.0",
|
20
|
-
"@types/react": "
|
21
|
-
"@types/react-dom": "
|
20
|
+
"@types/react": "19.1.13",
|
21
|
+
"@types/react-dom": "19.1.9",
|
22
22
|
"jsdom": "^26.1.0",
|
23
|
-
"react": "
|
24
|
-
"react-dom": "
|
23
|
+
"react": "19.1.0",
|
24
|
+
"react-dom": "19.1.0",
|
25
25
|
"react-window": "^1.8.11",
|
26
|
-
"typescript": "
|
27
|
-
"vite": "
|
26
|
+
"typescript": "5.9.2",
|
27
|
+
"vite": "7.1.7",
|
28
28
|
"vitest": "3.2.4",
|
29
|
-
"@livestore/utils-dev": "0.4.0-dev.
|
30
|
-
"@livestore/adapter-web": "0.4.0-dev.
|
29
|
+
"@livestore/utils-dev": "0.4.0-dev.10",
|
30
|
+
"@livestore/adapter-web": "0.4.0-dev.10"
|
31
31
|
},
|
32
32
|
"files": [
|
33
33
|
"package.json",
|
@@ -36,7 +36,7 @@
|
|
36
36
|
],
|
37
37
|
"license": "Apache-2.0",
|
38
38
|
"peerDependencies": {
|
39
|
-
"react": "^19.
|
39
|
+
"react": "^19.1.0"
|
40
40
|
},
|
41
41
|
"publishConfig": {
|
42
42
|
"access": "public"
|
@@ -1,4 +1,4 @@
|
|
1
|
-
/** biome-ignore-all lint/a11y: test */
|
1
|
+
/** biome-ignore-all lint/a11y: test files need a11y disabled */
|
2
2
|
import { makeInMemoryAdapter } from '@livestore/adapter-web'
|
3
3
|
import { queryDb, type Store } from '@livestore/livestore'
|
4
4
|
import { Schema } from '@livestore/utils/effect'
|
@@ -9,7 +9,7 @@ import type {
|
|
9
9
|
LiveStoreContext as StoreContext_,
|
10
10
|
} from '@livestore/livestore'
|
11
11
|
import { createStore, makeShutdownDeferred, StoreInterrupted } from '@livestore/livestore'
|
12
|
-
import { errorToString, IS_REACT_NATIVE, LS_DEV } from '@livestore/utils'
|
12
|
+
import { errorToString, IS_REACT_NATIVE, LS_DEV, omitUndefineds } from '@livestore/utils'
|
13
13
|
import type { OtelTracer } from '@livestore/utils/effect'
|
14
14
|
import {
|
15
15
|
Cause,
|
@@ -90,7 +90,7 @@ const defaultRenderShutdown = (cause: IntentionalShutdownCause | StoreInterrupte
|
|
90
90
|
const reason =
|
91
91
|
cause._tag === 'LiveStore.StoreInterrupted'
|
92
92
|
? `interrupted due to: ${cause.reason}`
|
93
|
-
: cause._tag === '
|
93
|
+
: cause._tag === 'InvalidPushError' || cause._tag === 'InvalidPullError'
|
94
94
|
? `sync error: ${cause.cause}`
|
95
95
|
: cause.reason === 'devtools-import'
|
96
96
|
? 'devtools import'
|
@@ -124,19 +124,21 @@ export const LiveStoreProvider = ({
|
|
124
124
|
confirmUnsavedChanges = true,
|
125
125
|
syncPayload,
|
126
126
|
debug,
|
127
|
-
}: LiveStoreProviderProps &
|
127
|
+
}: LiveStoreProviderProps & React.PropsWithChildren): React.ReactNode => {
|
128
128
|
const storeCtx = useCreateStore({
|
129
129
|
storeId,
|
130
130
|
schema,
|
131
|
-
otelOptions,
|
132
|
-
boot,
|
133
131
|
adapter,
|
134
132
|
batchUpdates,
|
135
|
-
disableDevtools,
|
136
|
-
signal,
|
137
133
|
confirmUnsavedChanges,
|
138
|
-
|
139
|
-
|
134
|
+
...omitUndefineds({
|
135
|
+
otelOptions,
|
136
|
+
boot,
|
137
|
+
disableDevtools,
|
138
|
+
signal,
|
139
|
+
syncPayload,
|
140
|
+
debug,
|
141
|
+
}),
|
140
142
|
})
|
141
143
|
|
142
144
|
if (storeCtx.stage === 'error') {
|
@@ -330,21 +332,23 @@ const useCreateStore = ({
|
|
330
332
|
const store = yield* createStore({
|
331
333
|
schema,
|
332
334
|
storeId,
|
333
|
-
boot,
|
334
335
|
adapter,
|
335
|
-
batchUpdates,
|
336
|
-
disableDevtools,
|
337
336
|
shutdownDeferred,
|
338
|
-
|
339
|
-
|
340
|
-
|
341
|
-
|
337
|
+
...omitUndefineds({
|
338
|
+
boot,
|
339
|
+
batchUpdates,
|
340
|
+
disableDevtools,
|
341
|
+
context,
|
342
|
+
params,
|
343
|
+
confirmUnsavedChanges,
|
344
|
+
syncPayload,
|
345
|
+
}),
|
342
346
|
onBootStatus: (status) => {
|
343
347
|
if (ctxValueRef.current.value.stage === 'running' || ctxValueRef.current.value.stage === 'error') return
|
344
348
|
// NOTE sometimes when status come in in rapid succession, only the last value will be rendered by React
|
345
349
|
setContextValue(status)
|
346
350
|
},
|
347
|
-
debug: { instanceId: debugInstanceId },
|
351
|
+
debug: { ...omitUndefineds({ instanceId: debugInstanceId }) },
|
348
352
|
}).pipe(Effect.tapErrorCause((cause) => Deferred.failCause(shutdownDeferred, cause)))
|
349
353
|
|
350
354
|
setContextValue({ stage: 'running', store })
|
@@ -356,7 +360,8 @@ const useCreateStore = ({
|
|
356
360
|
yield* Deferred.await(shutdownDeferred).pipe(
|
357
361
|
Effect.tapErrorCause((cause) => Effect.logDebug('[@livestore/livestore/react] shutdown', Cause.pretty(cause))),
|
358
362
|
Effect.tap((intentionalShutdown) => shutdownContext(intentionalShutdown)),
|
359
|
-
Effect.catchTag('
|
363
|
+
Effect.catchTag('InvalidPushError', (cause) => shutdownContext(cause)),
|
364
|
+
Effect.catchTag('InvalidPullError', (cause) => shutdownContext(cause)),
|
360
365
|
Effect.catchTag('LiveStore.StoreInterrupted', (cause) => shutdownContext(cause)),
|
361
366
|
Effect.tapError((error) => Effect.sync(() => setContextValue({ stage: 'error', error }))),
|
362
367
|
Effect.tapDefect((defect) => Effect.sync(() => setContextValue({ stage: 'error', error: defect }))),
|
@@ -366,7 +371,7 @@ const useCreateStore = ({
|
|
366
371
|
Effect.scoped,
|
367
372
|
Effect.withSpan('@livestore/react:useCreateStore'),
|
368
373
|
LS_DEV ? TaskTracing.withAsyncTaggingTracing((name: string) => (console as any).createTask(name)) : identity,
|
369
|
-
provideOtel({ parentSpanContext: otelOptions?.rootSpanContext, otelTracer: otelOptions?.tracer }),
|
374
|
+
provideOtel(omitUndefineds({ parentSpanContext: otelOptions?.rootSpanContext, otelTracer: otelOptions?.tracer })),
|
370
375
|
Effect.tapCauseLogPretty,
|
371
376
|
Effect.annotateLogs({ thread: 'window' }),
|
372
377
|
Effect.provide(Logger.prettyWithThread('window')),
|
@@ -47,29 +47,6 @@ exports[`useClientDocument > otel > should update the data based on component ke
|
|
47
47
|
},
|
48
48
|
{
|
49
49
|
"_name": "LiveStore:commits",
|
50
|
-
"children": [
|
51
|
-
{
|
52
|
-
"_name": "LiveStore:commit",
|
53
|
-
"attributes": {
|
54
|
-
"livestore.eventTags": [
|
55
|
-
"UserInfoSet",
|
56
|
-
],
|
57
|
-
"livestore.eventsCount": 1,
|
58
|
-
},
|
59
|
-
"children": [
|
60
|
-
{
|
61
|
-
"_name": "livestore.in-memory-db:execute",
|
62
|
-
"attributes": {
|
63
|
-
"sql.query": "
|
64
|
-
INSERT INTO 'UserInfo' (id, value)
|
65
|
-
VALUES (?, ?)
|
66
|
-
ON CONFLICT (id) DO UPDATE SET value = json_set(value, ?, json(?))
|
67
|
-
",
|
68
|
-
},
|
69
|
-
},
|
70
|
-
],
|
71
|
-
},
|
72
|
-
],
|
73
50
|
},
|
74
51
|
{
|
75
52
|
"_name": "LiveStore:queries",
|
@@ -89,28 +66,6 @@ exports[`useClientDocument > otel > should update the data based on component ke
|
|
89
66
|
"sql.rowsCount": 0,
|
90
67
|
},
|
91
68
|
},
|
92
|
-
{
|
93
|
-
"_name": "LiveStore:commit",
|
94
|
-
"attributes": {
|
95
|
-
"livestore.commitLabel": "UserInfo.set:u1",
|
96
|
-
"livestore.eventTags": [
|
97
|
-
"UserInfoSet",
|
98
|
-
],
|
99
|
-
"livestore.eventsCount": 1,
|
100
|
-
},
|
101
|
-
"children": [
|
102
|
-
{
|
103
|
-
"_name": "livestore.in-memory-db:execute",
|
104
|
-
"attributes": {
|
105
|
-
"sql.query": "
|
106
|
-
INSERT INTO 'UserInfo' (id, value)
|
107
|
-
VALUES (?, ?)
|
108
|
-
ON CONFLICT (id) DO UPDATE SET value = json_set(json_set(value, ?, json(?)), ?, json(?))
|
109
|
-
",
|
110
|
-
},
|
111
|
-
},
|
112
|
-
],
|
113
|
-
},
|
114
69
|
{
|
115
70
|
"_name": "db:SELECT * FROM 'UserInfo' WHERE id = ?",
|
116
71
|
"attributes": {
|
@@ -226,6 +181,88 @@ exports[`useClientDocument > otel > should update the data based on component ke
|
|
226
181
|
}
|
227
182
|
`;
|
228
183
|
|
184
|
+
exports[`useClientDocument > otel > should update the data based on component key strictMode={ strictMode: false } 2`] = `
|
185
|
+
[
|
186
|
+
{
|
187
|
+
"_name": "LiveStore:commit",
|
188
|
+
"attributes": {
|
189
|
+
"livestore.commitLabel": "UserInfo.set:u1",
|
190
|
+
"livestore.eventTags": "[
|
191
|
+
"UserInfoSet"
|
192
|
+
]",
|
193
|
+
"livestore.eventsCount": 1,
|
194
|
+
},
|
195
|
+
"children": [
|
196
|
+
{
|
197
|
+
"_name": "client-session-sync-processor:push",
|
198
|
+
"attributes": {
|
199
|
+
"batchSize": 1,
|
200
|
+
"eventCounts": "{
|
201
|
+
"UserInfoSet": 1
|
202
|
+
}",
|
203
|
+
"mergeResultTag": "advance",
|
204
|
+
},
|
205
|
+
"children": [
|
206
|
+
{
|
207
|
+
"_name": "client-session-sync-processor:materialize-event",
|
208
|
+
"children": [
|
209
|
+
{
|
210
|
+
"_name": "livestore.in-memory-db:execute",
|
211
|
+
"attributes": {
|
212
|
+
"sql.query": "
|
213
|
+
INSERT INTO 'UserInfo' (id, value)
|
214
|
+
VALUES (?, ?)
|
215
|
+
ON CONFLICT (id) DO UPDATE SET value = json_set(json_set(value, ?, json(?)), ?, json(?))
|
216
|
+
",
|
217
|
+
},
|
218
|
+
},
|
219
|
+
],
|
220
|
+
},
|
221
|
+
],
|
222
|
+
},
|
223
|
+
],
|
224
|
+
},
|
225
|
+
{
|
226
|
+
"_name": "LiveStore:commit",
|
227
|
+
"attributes": {
|
228
|
+
"livestore.eventTags": "[
|
229
|
+
"UserInfoSet"
|
230
|
+
]",
|
231
|
+
"livestore.eventsCount": 1,
|
232
|
+
},
|
233
|
+
"children": [
|
234
|
+
{
|
235
|
+
"_name": "client-session-sync-processor:push",
|
236
|
+
"attributes": {
|
237
|
+
"batchSize": 1,
|
238
|
+
"eventCounts": "{
|
239
|
+
"UserInfoSet": 1
|
240
|
+
}",
|
241
|
+
"mergeResultTag": "advance",
|
242
|
+
},
|
243
|
+
"children": [
|
244
|
+
{
|
245
|
+
"_name": "client-session-sync-processor:materialize-event",
|
246
|
+
"children": [
|
247
|
+
{
|
248
|
+
"_name": "livestore.in-memory-db:execute",
|
249
|
+
"attributes": {
|
250
|
+
"sql.query": "
|
251
|
+
INSERT INTO 'UserInfo' (id, value)
|
252
|
+
VALUES (?, ?)
|
253
|
+
ON CONFLICT (id) DO UPDATE SET value = json_set(value, ?, json(?))
|
254
|
+
",
|
255
|
+
},
|
256
|
+
},
|
257
|
+
],
|
258
|
+
},
|
259
|
+
],
|
260
|
+
},
|
261
|
+
],
|
262
|
+
},
|
263
|
+
]
|
264
|
+
`;
|
265
|
+
|
229
266
|
exports[`useClientDocument > otel > should update the data based on component key strictMode={ strictMode: true } 1`] = `
|
230
267
|
{
|
231
268
|
"_name": "createStore",
|
@@ -273,29 +310,6 @@ exports[`useClientDocument > otel > should update the data based on component ke
|
|
273
310
|
},
|
274
311
|
{
|
275
312
|
"_name": "LiveStore:commits",
|
276
|
-
"children": [
|
277
|
-
{
|
278
|
-
"_name": "LiveStore:commit",
|
279
|
-
"attributes": {
|
280
|
-
"livestore.eventTags": [
|
281
|
-
"UserInfoSet",
|
282
|
-
],
|
283
|
-
"livestore.eventsCount": 1,
|
284
|
-
},
|
285
|
-
"children": [
|
286
|
-
{
|
287
|
-
"_name": "livestore.in-memory-db:execute",
|
288
|
-
"attributes": {
|
289
|
-
"sql.query": "
|
290
|
-
INSERT INTO 'UserInfo' (id, value)
|
291
|
-
VALUES (?, ?)
|
292
|
-
ON CONFLICT (id) DO UPDATE SET value = json_set(value, ?, json(?))
|
293
|
-
",
|
294
|
-
},
|
295
|
-
},
|
296
|
-
],
|
297
|
-
},
|
298
|
-
],
|
299
313
|
},
|
300
314
|
{
|
301
315
|
"_name": "LiveStore:queries",
|
@@ -315,28 +329,6 @@ exports[`useClientDocument > otel > should update the data based on component ke
|
|
315
329
|
"sql.rowsCount": 0,
|
316
330
|
},
|
317
331
|
},
|
318
|
-
{
|
319
|
-
"_name": "LiveStore:commit",
|
320
|
-
"attributes": {
|
321
|
-
"livestore.commitLabel": "UserInfo.set:u1",
|
322
|
-
"livestore.eventTags": [
|
323
|
-
"UserInfoSet",
|
324
|
-
],
|
325
|
-
"livestore.eventsCount": 1,
|
326
|
-
},
|
327
|
-
"children": [
|
328
|
-
{
|
329
|
-
"_name": "livestore.in-memory-db:execute",
|
330
|
-
"attributes": {
|
331
|
-
"sql.query": "
|
332
|
-
INSERT INTO 'UserInfo' (id, value)
|
333
|
-
VALUES (?, ?)
|
334
|
-
ON CONFLICT (id) DO UPDATE SET value = json_set(json_set(value, ?, json(?)), ?, json(?))
|
335
|
-
",
|
336
|
-
},
|
337
|
-
},
|
338
|
-
],
|
339
|
-
},
|
340
332
|
{
|
341
333
|
"_name": "db:SELECT * FROM 'UserInfo' WHERE id = ?",
|
342
334
|
"attributes": {
|
@@ -390,6 +382,88 @@ exports[`useClientDocument > otel > should update the data based on component ke
|
|
390
382
|
}
|
391
383
|
`;
|
392
384
|
|
385
|
+
exports[`useClientDocument > otel > should update the data based on component key strictMode={ strictMode: true } 2`] = `
|
386
|
+
[
|
387
|
+
{
|
388
|
+
"_name": "LiveStore:commit",
|
389
|
+
"attributes": {
|
390
|
+
"livestore.commitLabel": "UserInfo.set:u1",
|
391
|
+
"livestore.eventTags": "[
|
392
|
+
"UserInfoSet"
|
393
|
+
]",
|
394
|
+
"livestore.eventsCount": 1,
|
395
|
+
},
|
396
|
+
"children": [
|
397
|
+
{
|
398
|
+
"_name": "client-session-sync-processor:push",
|
399
|
+
"attributes": {
|
400
|
+
"batchSize": 1,
|
401
|
+
"eventCounts": "{
|
402
|
+
"UserInfoSet": 1
|
403
|
+
}",
|
404
|
+
"mergeResultTag": "advance",
|
405
|
+
},
|
406
|
+
"children": [
|
407
|
+
{
|
408
|
+
"_name": "client-session-sync-processor:materialize-event",
|
409
|
+
"children": [
|
410
|
+
{
|
411
|
+
"_name": "livestore.in-memory-db:execute",
|
412
|
+
"attributes": {
|
413
|
+
"sql.query": "
|
414
|
+
INSERT INTO 'UserInfo' (id, value)
|
415
|
+
VALUES (?, ?)
|
416
|
+
ON CONFLICT (id) DO UPDATE SET value = json_set(json_set(value, ?, json(?)), ?, json(?))
|
417
|
+
",
|
418
|
+
},
|
419
|
+
},
|
420
|
+
],
|
421
|
+
},
|
422
|
+
],
|
423
|
+
},
|
424
|
+
],
|
425
|
+
},
|
426
|
+
{
|
427
|
+
"_name": "LiveStore:commit",
|
428
|
+
"attributes": {
|
429
|
+
"livestore.eventTags": "[
|
430
|
+
"UserInfoSet"
|
431
|
+
]",
|
432
|
+
"livestore.eventsCount": 1,
|
433
|
+
},
|
434
|
+
"children": [
|
435
|
+
{
|
436
|
+
"_name": "client-session-sync-processor:push",
|
437
|
+
"attributes": {
|
438
|
+
"batchSize": 1,
|
439
|
+
"eventCounts": "{
|
440
|
+
"UserInfoSet": 1
|
441
|
+
}",
|
442
|
+
"mergeResultTag": "advance",
|
443
|
+
},
|
444
|
+
"children": [
|
445
|
+
{
|
446
|
+
"_name": "client-session-sync-processor:materialize-event",
|
447
|
+
"children": [
|
448
|
+
{
|
449
|
+
"_name": "livestore.in-memory-db:execute",
|
450
|
+
"attributes": {
|
451
|
+
"sql.query": "
|
452
|
+
INSERT INTO 'UserInfo' (id, value)
|
453
|
+
VALUES (?, ?)
|
454
|
+
ON CONFLICT (id) DO UPDATE SET value = json_set(value, ?, json(?))
|
455
|
+
",
|
456
|
+
},
|
457
|
+
},
|
458
|
+
],
|
459
|
+
},
|
460
|
+
],
|
461
|
+
},
|
462
|
+
],
|
463
|
+
},
|
464
|
+
]
|
465
|
+
`;
|
466
|
+
|
393
467
|
exports[`useClientDocument > should update the data based on component key 1`] = `
|
394
468
|
{
|
395
469
|
"atoms": [
|
@@ -443,7 +517,7 @@ exports[`useClientDocument > should update the data based on component key 1`] =
|
|
443
517
|
"refreshes": 1,
|
444
518
|
"sub": [],
|
445
519
|
"super": [
|
446
|
-
"node-
|
520
|
+
"node-6",
|
447
521
|
],
|
448
522
|
},
|
449
523
|
{
|
@@ -464,10 +538,27 @@ exports[`useClientDocument > should update the data based on component key 1`] =
|
|
464
538
|
"super": [],
|
465
539
|
},
|
466
540
|
{
|
467
|
-
"_tag": "
|
541
|
+
"_tag": "ref",
|
468
542
|
"id": "node-5",
|
469
543
|
"isDestroyed": false,
|
470
544
|
"isDirty": false,
|
545
|
+
"label": "tableRef:Kv",
|
546
|
+
"meta": {
|
547
|
+
"liveStoreRefType": "table",
|
548
|
+
},
|
549
|
+
"previousResult": {
|
550
|
+
"_tag": "Some",
|
551
|
+
"value": "null",
|
552
|
+
},
|
553
|
+
"refreshes": 0,
|
554
|
+
"sub": [],
|
555
|
+
"super": [],
|
556
|
+
},
|
557
|
+
{
|
558
|
+
"_tag": "thunk",
|
559
|
+
"id": "node-6",
|
560
|
+
"isDestroyed": false,
|
561
|
+
"isDirty": false,
|
471
562
|
"label": "UserInfo.get:u1:results",
|
472
563
|
"meta": {
|
473
564
|
"liveStoreThunkType": "db.result",
|
@@ -481,7 +572,7 @@ exports[`useClientDocument > should update the data based on component key 1`] =
|
|
481
572
|
"node-3",
|
482
573
|
],
|
483
574
|
"super": [
|
484
|
-
"node-
|
575
|
+
"node-7",
|
485
576
|
],
|
486
577
|
},
|
487
578
|
],
|
@@ -489,12 +580,12 @@ exports[`useClientDocument > should update the data based on component key 1`] =
|
|
489
580
|
"effects": [
|
490
581
|
{
|
491
582
|
"_tag": "effect",
|
492
|
-
"id": "node-
|
583
|
+
"id": "node-7",
|
493
584
|
"invocations": 1,
|
494
585
|
"isDestroyed": false,
|
495
586
|
"label": "subscribe:UserInfo.get:u1",
|
496
587
|
"sub": [
|
497
|
-
"node-
|
588
|
+
"node-6",
|
498
589
|
],
|
499
590
|
},
|
500
591
|
],
|
@@ -554,7 +645,7 @@ exports[`useClientDocument > should update the data based on component key 2`] =
|
|
554
645
|
"refreshes": 2,
|
555
646
|
"sub": [],
|
556
647
|
"super": [
|
557
|
-
"node-
|
648
|
+
"node-8",
|
558
649
|
],
|
559
650
|
},
|
560
651
|
{
|
@@ -574,9 +665,26 @@ exports[`useClientDocument > should update the data based on component key 2`] =
|
|
574
665
|
"sub": [],
|
575
666
|
"super": [],
|
576
667
|
},
|
668
|
+
{
|
669
|
+
"_tag": "ref",
|
670
|
+
"id": "node-5",
|
671
|
+
"isDestroyed": false,
|
672
|
+
"isDirty": false,
|
673
|
+
"label": "tableRef:Kv",
|
674
|
+
"meta": {
|
675
|
+
"liveStoreRefType": "table",
|
676
|
+
},
|
677
|
+
"previousResult": {
|
678
|
+
"_tag": "Some",
|
679
|
+
"value": "null",
|
680
|
+
},
|
681
|
+
"refreshes": 0,
|
682
|
+
"sub": [],
|
683
|
+
"super": [],
|
684
|
+
},
|
577
685
|
{
|
578
686
|
"_tag": "thunk",
|
579
|
-
"id": "node-
|
687
|
+
"id": "node-8",
|
580
688
|
"isDestroyed": false,
|
581
689
|
"isDirty": false,
|
582
690
|
"label": "UserInfo.get:u2:results",
|
@@ -592,7 +700,7 @@ exports[`useClientDocument > should update the data based on component key 2`] =
|
|
592
700
|
"node-3",
|
593
701
|
],
|
594
702
|
"super": [
|
595
|
-
"node-
|
703
|
+
"node-9",
|
596
704
|
],
|
597
705
|
},
|
598
706
|
],
|
@@ -600,12 +708,12 @@ exports[`useClientDocument > should update the data based on component key 2`] =
|
|
600
708
|
"effects": [
|
601
709
|
{
|
602
710
|
"_tag": "effect",
|
603
|
-
"id": "node-
|
711
|
+
"id": "node-9",
|
604
712
|
"invocations": 1,
|
605
713
|
"isDestroyed": false,
|
606
714
|
"label": "subscribe:UserInfo.get:u2",
|
607
715
|
"sub": [
|
608
|
-
"node-
|
716
|
+
"node-8",
|
609
717
|
],
|
610
718
|
},
|
611
719
|
],
|