@ersbeth/picoflow 2.0.2 → 2.1.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/LICENSE +21 -0
- package/README.md +25 -0
- package/SKILL.md +106 -0
- package/dist/picoflow.js +204 -60
- package/dist/types/api/base/flowObservable.d.ts +3 -3
- package/dist/types/api/base/flowObservable.d.ts.map +1 -1
- package/dist/types/api/base/flowSubscribable.d.ts +2 -2
- package/dist/types/api/base/flowSubscribable.d.ts.map +1 -1
- package/dist/types/api/base/flowTracker.d.ts +1 -1
- package/dist/types/api/base/flowTracker.d.ts.map +1 -1
- package/dist/types/api/base/index.d.ts +4 -4
- package/dist/types/api/base/index.d.ts.map +1 -1
- package/dist/types/api/index.d.ts +2 -2
- package/dist/types/api/index.d.ts.map +1 -1
- package/dist/types/api/nodes/async/flowConstantAsync.d.ts +1 -1
- package/dist/types/api/nodes/async/flowConstantAsync.d.ts.map +1 -1
- package/dist/types/api/nodes/async/flowDerivationAsync.d.ts +3 -3
- package/dist/types/api/nodes/async/flowDerivationAsync.d.ts.map +1 -1
- package/dist/types/api/nodes/async/flowStateAsync.d.ts +3 -3
- package/dist/types/api/nodes/async/flowStateAsync.d.ts.map +1 -1
- package/dist/types/api/nodes/async/flowWritableDerivationAsync.d.ts +2 -2
- package/dist/types/api/nodes/async/flowWritableDerivationAsync.d.ts.map +1 -1
- package/dist/types/api/nodes/async/index.d.ts +4 -4
- package/dist/types/api/nodes/async/index.d.ts.map +1 -1
- package/dist/types/api/nodes/collections/flowArray.d.ts +7 -4
- package/dist/types/api/nodes/collections/flowArray.d.ts.map +1 -1
- package/dist/types/api/nodes/collections/flowMap.d.ts +3 -2
- package/dist/types/api/nodes/collections/flowMap.d.ts.map +1 -1
- package/dist/types/api/nodes/collections/index.d.ts +2 -2
- package/dist/types/api/nodes/collections/index.d.ts.map +1 -1
- package/dist/types/api/nodes/flowEffect.d.ts +2 -2
- package/dist/types/api/nodes/flowEffect.d.ts.map +1 -1
- package/dist/types/api/nodes/flowSignal.d.ts +1 -1
- package/dist/types/api/nodes/flowSignal.d.ts.map +1 -1
- package/dist/types/api/nodes/flowValue.d.ts +2 -2
- package/dist/types/api/nodes/flowValue.d.ts.map +1 -1
- package/dist/types/api/nodes/index.d.ts +7 -7
- package/dist/types/api/nodes/index.d.ts.map +1 -1
- package/dist/types/api/nodes/sync/flowConstant.d.ts +2 -2
- package/dist/types/api/nodes/sync/flowConstant.d.ts.map +1 -1
- package/dist/types/api/nodes/sync/flowDerivation.d.ts +3 -3
- package/dist/types/api/nodes/sync/flowDerivation.d.ts.map +1 -1
- package/dist/types/api/nodes/sync/flowState.d.ts +3 -3
- package/dist/types/api/nodes/sync/flowState.d.ts.map +1 -1
- package/dist/types/api/nodes/sync/flowWritableDerivation.d.ts +2 -2
- package/dist/types/api/nodes/sync/flowWritableDerivation.d.ts.map +1 -1
- package/dist/types/api/nodes/sync/index.d.ts +4 -4
- package/dist/types/api/nodes/sync/index.d.ts.map +1 -1
- package/dist/types/api/nodes/utils.d.ts +1 -1
- package/dist/types/api/nodes/utils.d.ts.map +1 -1
- package/dist/types/base/disposable.d.ts +1 -1
- package/dist/types/base/disposable.d.ts.map +1 -1
- package/dist/types/base/executionStack.d.ts +22 -1
- package/dist/types/base/executionStack.d.ts.map +1 -1
- package/dist/types/base/index.d.ts +5 -5
- package/dist/types/base/index.d.ts.map +1 -1
- package/dist/types/base/node.d.ts +4 -4
- package/dist/types/base/node.d.ts.map +1 -1
- package/dist/types/base/observable.d.ts +3 -3
- package/dist/types/base/observable.d.ts.map +1 -1
- package/dist/types/base/observer.d.ts +2 -2
- package/dist/types/base/observer.d.ts.map +1 -1
- package/dist/types/converters/index.d.ts +1 -1
- package/dist/types/converters/index.d.ts.map +1 -1
- package/dist/types/converters/solid.d.ts +12 -8
- package/dist/types/converters/solid.d.ts.map +1 -1
- package/dist/types/index.d.ts +2 -2
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/nodes/actionNode.d.ts +23 -0
- package/dist/types/nodes/actionNode.d.ts.map +1 -0
- package/dist/types/nodes/arrayNode.d.ts +4 -3
- package/dist/types/nodes/arrayNode.d.ts.map +1 -1
- package/dist/types/nodes/effectNode.d.ts +18 -2
- package/dist/types/nodes/effectNode.d.ts.map +1 -1
- package/dist/types/nodes/index.d.ts +8 -7
- package/dist/types/nodes/index.d.ts.map +1 -1
- package/dist/types/nodes/mapNode.d.ts +4 -3
- package/dist/types/nodes/mapNode.d.ts.map +1 -1
- package/dist/types/nodes/signalNode.d.ts +2 -2
- package/dist/types/nodes/signalNode.d.ts.map +1 -1
- package/dist/types/nodes/valueAsyncNode.d.ts +3 -3
- package/dist/types/nodes/valueAsyncNode.d.ts.map +1 -1
- package/dist/types/nodes/valueNode.d.ts +3 -3
- package/dist/types/nodes/valueNode.d.ts.map +1 -1
- package/dist/types/nodes/valueSyncNode.d.ts +3 -3
- package/dist/types/nodes/valueSyncNode.d.ts.map +1 -1
- package/dist/types/schedulers/asyncScheduler.d.ts +2 -1
- package/dist/types/schedulers/asyncScheduler.d.ts.map +1 -1
- package/dist/types/schedulers/index.d.ts +4 -4
- package/dist/types/schedulers/index.d.ts.map +1 -1
- package/dist/types/schedulers/syncResolver.d.ts +1 -2
- package/dist/types/schedulers/syncResolver.d.ts.map +1 -1
- package/dist/types/schedulers/syncScheduler.d.ts +1 -1
- package/dist/types/schedulers/syncScheduler.d.ts.map +1 -1
- package/package.json +24 -1
- package/.gitlab-ci.yml +0 -24
- package/.vscode/settings.json +0 -5
- package/CHANGELOG.md +0 -94
- package/biome.json +0 -47
- package/docs/.vitepress/config.mts +0 -145
- package/docs/api/functions/array.md +0 -35
- package/docs/api/functions/constant.md +0 -33
- package/docs/api/functions/constantAsync.md +0 -69
- package/docs/api/functions/derivation.md +0 -34
- package/docs/api/functions/derivationAsync.md +0 -34
- package/docs/api/functions/from.md +0 -129
- package/docs/api/functions/isDisposable.md +0 -27
- package/docs/api/functions/map.md +0 -36
- package/docs/api/functions/signal.md +0 -21
- package/docs/api/functions/state.md +0 -67
- package/docs/api/functions/stateAsync.md +0 -69
- package/docs/api/functions/subscribe.md +0 -40
- package/docs/api/functions/writableDerivation.md +0 -33
- package/docs/api/functions/writableDerivationAsync.md +0 -34
- package/docs/api/index.md +0 -61
- package/docs/api/interfaces/FlowArray.md +0 -439
- package/docs/api/interfaces/FlowConstant.md +0 -220
- package/docs/api/interfaces/FlowConstantAsync.md +0 -221
- package/docs/api/interfaces/FlowDerivation.md +0 -241
- package/docs/api/interfaces/FlowDerivationAsync.md +0 -242
- package/docs/api/interfaces/FlowDisposable.md +0 -59
- package/docs/api/interfaces/FlowEffect.md +0 -64
- package/docs/api/interfaces/FlowMap.md +0 -374
- package/docs/api/interfaces/FlowObservable.md +0 -155
- package/docs/api/interfaces/FlowSignal.md +0 -156
- package/docs/api/interfaces/FlowState.md +0 -269
- package/docs/api/interfaces/FlowStateAsync.md +0 -268
- package/docs/api/interfaces/FlowSubscribable.md +0 -55
- package/docs/api/interfaces/FlowTracker.md +0 -61
- package/docs/api/interfaces/FlowValue.md +0 -222
- package/docs/api/interfaces/FlowWritableDerivation.md +0 -292
- package/docs/api/interfaces/FlowWritableDerivationAsync.md +0 -293
- package/docs/api/type-aliases/DerivationFunction.md +0 -28
- package/docs/api/type-aliases/DerivationFunctionAsync.md +0 -28
- package/docs/api/type-aliases/FlowArrayAction.md +0 -60
- package/docs/api/type-aliases/FlowDataTracker.md +0 -33
- package/docs/api/type-aliases/FlowMapAction.md +0 -48
- package/docs/api/type-aliases/FlowOnDataListener.md +0 -33
- package/docs/api/type-aliases/FlowOnErrorListener.md +0 -27
- package/docs/api/type-aliases/FlowOnPendingListener.md +0 -21
- package/docs/api/type-aliases/FlowReadonly.md +0 -22
- package/docs/api/type-aliases/InitFunction.md +0 -21
- package/docs/api/type-aliases/InitFunctionAsync.md +0 -21
- package/docs/api/type-aliases/NotPromise.md +0 -21
- package/docs/api/type-aliases/UpdateFunction.md +0 -27
- package/docs/api/type-aliases/UpdateFunctionAsync.md +0 -27
- package/docs/api/typedoc-sidebar.json +0 -65
- package/docs/examples/examples.md +0 -2311
- package/docs/examples/patterns.md +0 -649
- package/docs/guide/advanced/architecture.md +0 -1234
- package/docs/guide/advanced/disposal.md +0 -426
- package/docs/guide/advanced/migration-v1.md +0 -464
- package/docs/guide/advanced/migration-v2.md +0 -204
- package/docs/guide/advanced/solidjs.md +0 -135
- package/docs/guide/introduction/concepts.md +0 -57
- package/docs/guide/introduction/conventions.md +0 -30
- package/docs/guide/introduction/getting-started.md +0 -139
- package/docs/guide/introduction/lifecycle.md +0 -368
- package/docs/guide/primitives/array.md +0 -286
- package/docs/guide/primitives/constant.md +0 -207
- package/docs/guide/primitives/derivations.md +0 -281
- package/docs/guide/primitives/effects.md +0 -372
- package/docs/guide/primitives/map.md +0 -265
- package/docs/guide/primitives/overview.md +0 -92
- package/docs/guide/primitives/signal.md +0 -222
- package/docs/guide/primitives/state.md +0 -272
- package/docs/index.md +0 -47
- package/docs/public/logo.svg +0 -1
- package/src/api/base/flowDisposable.ts +0 -44
- package/src/api/base/flowObservable.ts +0 -28
- package/src/api/base/flowSubscribable.ts +0 -87
- package/src/api/base/flowTracker.ts +0 -7
- package/src/api/base/index.ts +0 -4
- package/src/api/index.ts +0 -2
- package/src/api/nodes/async/flowConstantAsync.ts +0 -36
- package/src/api/nodes/async/flowDerivationAsync.ts +0 -42
- package/src/api/nodes/async/flowStateAsync.ts +0 -47
- package/src/api/nodes/async/flowWritableDerivationAsync.ts +0 -33
- package/src/api/nodes/async/index.ts +0 -4
- package/src/api/nodes/collections/flowArray.ts +0 -155
- package/src/api/nodes/collections/flowMap.ts +0 -115
- package/src/api/nodes/collections/index.ts +0 -2
- package/src/api/nodes/flowEffect.ts +0 -42
- package/src/api/nodes/flowSignal.ts +0 -28
- package/src/api/nodes/flowValue.ts +0 -37
- package/src/api/nodes/index.ts +0 -7
- package/src/api/nodes/sync/flowConstant.ts +0 -33
- package/src/api/nodes/sync/flowDerivation.ts +0 -41
- package/src/api/nodes/sync/flowState.ts +0 -45
- package/src/api/nodes/sync/flowWritableDerivation.ts +0 -31
- package/src/api/nodes/sync/index.ts +0 -4
- package/src/api/nodes/utils.ts +0 -24
- package/src/base/disposable.ts +0 -18
- package/src/base/executionStack.ts +0 -42
- package/src/base/index.ts +0 -5
- package/src/base/node.ts +0 -98
- package/src/base/observable.ts +0 -92
- package/src/base/observer.ts +0 -51
- package/src/converters/index.ts +0 -1
- package/src/converters/solid.ts +0 -109
- package/src/index.ts +0 -2
- package/src/nodes/arrayNode.ts +0 -180
- package/src/nodes/effectNode.ts +0 -58
- package/src/nodes/index.ts +0 -7
- package/src/nodes/mapNode.ts +0 -125
- package/src/nodes/signalNode.ts +0 -19
- package/src/nodes/valueAsyncNode.ts +0 -85
- package/src/nodes/valueNode.ts +0 -148
- package/src/nodes/valueSyncNode.ts +0 -125
- package/src/schedulers/asyncResolver.ts +0 -78
- package/src/schedulers/asyncScheduler.ts +0 -66
- package/src/schedulers/index.ts +0 -4
- package/src/schedulers/pendingError.ts +0 -13
- package/src/schedulers/scheduler.ts +0 -9
- package/src/schedulers/syncResolver.ts +0 -69
- package/src/schedulers/syncScheduler.ts +0 -55
- package/test/base/pendingError.test.ts +0 -67
- package/test/converters/solid.derivation.browser.test.tsx +0 -69
- package/test/converters/solid.node.test.ts +0 -654
- package/test/converters/solid.state.browser.test.tsx +0 -1592
- package/test/reactivity/flowSignal.test.ts +0 -226
- package/test/reactivity/nodes/async/asyncScheduler/asyncResolver.test.ts +0 -593
- package/test/reactivity/nodes/async/asyncScheduler/asyncScheduler.test.ts +0 -317
- package/test/reactivity/nodes/async/flowConstantAsync.test.ts +0 -652
- package/test/reactivity/nodes/async/flowDerivation.test.ts +0 -898
- package/test/reactivity/nodes/async/flowDerivationAsync.test.ts +0 -1716
- package/test/reactivity/nodes/async/flowStateAsync.test.ts +0 -708
- package/test/reactivity/nodes/async/flowWritableDerivationAsync.test.ts +0 -614
- package/test/reactivity/nodes/collections/flowArray.asyncStates.test.ts +0 -1289
- package/test/reactivity/nodes/collections/flowArray.scalars.test.ts +0 -961
- package/test/reactivity/nodes/collections/flowArray.states.test.ts +0 -1035
- package/test/reactivity/nodes/collections/flowMap.asyncStates.test.ts +0 -960
- package/test/reactivity/nodes/collections/flowMap.scalars.test.ts +0 -775
- package/test/reactivity/nodes/collections/flowMap.states.test.ts +0 -958
- package/test/reactivity/nodes/sync/flowConstant.test.ts +0 -377
- package/test/reactivity/nodes/sync/flowDerivation.test.ts +0 -896
- package/test/reactivity/nodes/sync/flowState.test.ts +0 -341
- package/test/reactivity/nodes/sync/flowWritableDerivation.test.ts +0 -603
- package/test/vitest.d.ts +0 -10
- package/tsconfig.json +0 -37
- package/typedoc.json +0 -37
- package/vite.config.ts +0 -31
- package/vitest.browser.config.ts +0 -21
- package/vitest.config.ts +0 -17
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowSubscribable.d.ts","sourceRoot":"","sources":["../../../../src/api/base/flowSubscribable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowSubscribable.d.ts","sourceRoot":"","sources":["../../../../src/api/base/flowSubscribable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAEpD;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,eAAe,CAAC,CAAC,IAAI,CAAC,CAAC,EAAE,WAAW,KAAK,CAAC,CAAC;AAEvD;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,kBAAkB,CAAC,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,KAAK,IAAI,CAAC;AAEtD;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;AAEzD;;;;;;;;;;GAUG;AACH,MAAM,MAAM,qBAAqB,GAAG,MAAM,IAAI,CAAC;AAE/C;;;;;;;;GAQG;AACH,MAAM,WAAW,gBAAgB,CAAC,CAAC;IAC/B;;;;;;;;;;;;OAYG;IACH,SAAS,CACL,MAAM,EAAE,kBAAkB,CAAC,CAAC,CAAC,EAC7B,OAAO,CAAC,EAAE,mBAAmB,EAC7B,SAAS,CAAC,EAAE,qBAAqB,GAClC,UAAU,CAAC;CACjB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowTracker.d.ts","sourceRoot":"","sources":["../../../../src/api/base/flowTracker.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowTracker.d.ts","sourceRoot":"","sources":["../../../../src/api/base/flowTracker.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAE1D;;;GAGG;AACH,MAAM,WAAW,WAAY,SAAQ,cAAc;CAAG"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export * from './flowDisposable';
|
|
2
|
-
export * from './flowObservable';
|
|
3
|
-
export * from './flowSubscribable';
|
|
4
|
-
export * from './flowTracker';
|
|
1
|
+
export * from './flowDisposable.js';
|
|
2
|
+
export * from './flowObservable.js';
|
|
3
|
+
export * from './flowSubscribable.js';
|
|
4
|
+
export * from './flowTracker.js';
|
|
5
5
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/api/base/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/api/base/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC;AACtC,cAAc,kBAAkB,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './base';
|
|
2
|
-
export * from './nodes';
|
|
1
|
+
export * from './base/index.js';
|
|
2
|
+
export * from './nodes/index.js';
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowConstantAsync.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/flowConstantAsync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowConstantAsync.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/flowConstantAsync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAEjD,wDAAwD;AACxD,MAAM,MAAM,iBAAiB,CAAC,CAAC,IAAI,MAAM,OAAO,CAAC,CAAC,CAAC,CAAC;AAEpD;;;;;;;;;GASG;AACH,MAAM,WAAW,iBAAiB,CAAC,CAAC,CAAE,SAAQ,SAAS,CAAC,CAAC,CAAC;CAAG;AAE7D;;;;;;;;;;;;GAYG;AACH,wBAAgB,aAAa,CAAC,CAAC,EAAE,KAAK,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,iBAAiB,CAAC,CAAC,CAAC,CAAC;AAC1E,wBAAgB,aAAa,CAAC,CAAC,EAAE,WAAW,EAAE,iBAAiB,CAAC,CAAC,CAAC,GAAG,iBAAiB,CAAC,CAAC,CAAC,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FlowTracker } from '../../base';
|
|
2
|
-
import { FlowValue } from '../flowValue';
|
|
3
|
-
import { NotPromise } from '../utils';
|
|
1
|
+
import { FlowTracker } from '../../base/index.js';
|
|
2
|
+
import { FlowValue } from '../flowValue.js';
|
|
3
|
+
import { NotPromise } from '../utils.js';
|
|
4
4
|
/** Function that derives a value asynchronously from dependencies and optionally the previous value. */
|
|
5
5
|
export type DerivationFunctionAsync<T> = (tracker: FlowTracker, previous?: NotPromise<T> | undefined) => Promise<T>;
|
|
6
6
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowDerivationAsync.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/flowDerivationAsync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowDerivationAsync.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/flowDerivationAsync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C,wGAAwG;AACxG,MAAM,MAAM,uBAAuB,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,WAAW,EAAE,QAAQ,CAAC,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,SAAS,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;AAEpH;;;;;;;;;;GAUG;AACH,MAAM,WAAW,mBAAmB,CAAC,CAAC,CAAE,SAAQ,SAAS,CAAC,CAAC,CAAC;IACxD;;OAEG;IACH,OAAO,IAAI,IAAI,CAAC;CACnB;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,eAAe,CAAC,CAAC,EAAE,OAAO,EAAE,uBAAuB,CAAC,CAAC,CAAC,GAAG,mBAAmB,CAAC,CAAC,CAAC,CAE9F"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FlowValue } from '../flowValue';
|
|
2
|
-
import { NotPromise } from '../utils';
|
|
3
|
-
import { InitFunctionAsync } from './flowConstantAsync';
|
|
1
|
+
import { FlowValue } from '../flowValue.js';
|
|
2
|
+
import { NotPromise } from '../utils.js';
|
|
3
|
+
import { InitFunctionAsync } from './flowConstantAsync.js';
|
|
4
4
|
/** Function that updates a value asynchronously based on the previous value. */
|
|
5
5
|
export type UpdateFunctionAsync<T> = (previous: NotPromise<T> | undefined) => Promise<T>;
|
|
6
6
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowStateAsync.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/flowStateAsync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowStateAsync.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/flowStateAsync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAC9C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAEhE,gFAAgF;AAChF,MAAM,MAAM,mBAAmB,CAAC,CAAC,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,SAAS,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;AAEzF;;;;;;;;;GASG;AACH,MAAM,WAAW,cAAc,CAAC,CAAC,CAAE,SAAQ,SAAS,CAAC,CAAC,CAAC;IACnD;;;;;OAKG;IACH,GAAG,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC;IAC/B,GAAG,CAAC,OAAO,EAAE,mBAAmB,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC;CAC9C;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,UAAU,CAAC,CAAC,EAAE,KAAK,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAAC;AACpE,wBAAgB,UAAU,CAAC,CAAC,EAAE,WAAW,EAAE,iBAAiB,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { DerivationFunctionAsync, FlowDerivationAsync } from './flowDerivationAsync';
|
|
2
|
-
import { FlowStateAsync } from './flowStateAsync';
|
|
1
|
+
import { DerivationFunctionAsync, FlowDerivationAsync } from './flowDerivationAsync.js';
|
|
2
|
+
import { FlowStateAsync } from './flowStateAsync.js';
|
|
3
3
|
/**
|
|
4
4
|
* Writable reactive value that recomputes asynchronously when dependencies change, but can be manually overridden.
|
|
5
5
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowWritableDerivationAsync.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/flowWritableDerivationAsync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,uBAAuB,EAAE,mBAAmB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowWritableDerivationAsync.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/flowWritableDerivationAsync.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,uBAAuB,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC7F,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAE1D;;;;;;;;;;GAUG;AACH,MAAM,WAAW,2BAA2B,CAAC,CAAC,CAAE,SAAQ,cAAc,CAAC,CAAC,CAAC,EAAE,mBAAmB,CAAC,CAAC,CAAC;CAAG;AAEpG;;;;;;;;;;;;GAYG;AACH,wBAAgB,uBAAuB,CAAC,CAAC,EAAE,OAAO,EAAE,uBAAuB,CAAC,CAAC,CAAC,GAAG,2BAA2B,CAAC,CAAC,CAAC,CAE9G"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export * from './flowConstantAsync';
|
|
2
|
-
export * from './flowDerivationAsync';
|
|
3
|
-
export * from './flowStateAsync';
|
|
4
|
-
export * from './flowWritableDerivationAsync';
|
|
1
|
+
export * from './flowConstantAsync.js';
|
|
2
|
+
export * from './flowDerivationAsync.js';
|
|
3
|
+
export * from './flowStateAsync.js';
|
|
4
|
+
export * from './flowWritableDerivationAsync.js';
|
|
5
5
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/async/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kCAAkC,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { FlowState } from '../sync/flowState';
|
|
1
|
+
import { FlowState } from '../sync/flowState.js';
|
|
2
2
|
/**
|
|
3
3
|
* Discriminated union representing all possible array mutation operations.
|
|
4
4
|
*
|
|
@@ -70,7 +70,8 @@ export interface FlowArray<T> extends FlowState<T[]> {
|
|
|
70
70
|
push(item: T): void;
|
|
71
71
|
/**
|
|
72
72
|
* Removes and returns the last item from the array.
|
|
73
|
-
* Emits a "pop" action to $lastAction.
|
|
73
|
+
* Emits a "pop" action to $lastAction when an item is removed.
|
|
74
|
+
* If the array is already empty, returns undefined without notifying dependents or updating $lastAction.
|
|
74
75
|
*
|
|
75
76
|
* @returns The removed item, or undefined if the array was empty
|
|
76
77
|
*/
|
|
@@ -84,7 +85,8 @@ export interface FlowArray<T> extends FlowState<T[]> {
|
|
|
84
85
|
unshift(item: T): void;
|
|
85
86
|
/**
|
|
86
87
|
* Removes and returns the first item from the array.
|
|
87
|
-
* Emits a "shift" action to $lastAction.
|
|
88
|
+
* Emits a "shift" action to $lastAction when an item is removed.
|
|
89
|
+
* If the array is already empty, returns undefined without notifying dependents or updating $lastAction.
|
|
88
90
|
*
|
|
89
91
|
* @returns The removed item, or undefined if the array was empty
|
|
90
92
|
*/
|
|
@@ -112,7 +114,8 @@ export interface FlowArray<T> extends FlowState<T[]> {
|
|
|
112
114
|
length: number;
|
|
113
115
|
/**
|
|
114
116
|
* Reactive state containing the last mutation operation performed on the array.
|
|
115
|
-
*
|
|
117
|
+
* `.subscribe()` invokes its callback once per mutation (including several in the same tick).
|
|
118
|
+
* `get()` / `pick()` expose only the latest action snapshot.
|
|
116
119
|
*/
|
|
117
120
|
$lastAction: FlowState<FlowArrayAction<T>>;
|
|
118
121
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowArray.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/collections/flowArray.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowArray.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/collections/flowArray.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEtD;;;;;;;;;GASG;AACH,MAAM,MAAM,eAAe,CAAC,CAAC,IACvB;IACI,IAAI,EAAE,KAAK,CAAC;IACZ,QAAQ,EAAE,CAAC,EAAE,CAAC;IACd,YAAY,EAAE,CAAC,EAAE,CAAC;CACrB,GACD;IACI,IAAI,EAAE,QAAQ,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,CAAC,CAAC;IACX,WAAW,EAAE,CAAC,GAAG,SAAS,CAAC;CAC9B,GACD;IACI,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,CAAC,CAAC;CAChB,GACD;IACI,IAAI,EAAE,KAAK,CAAC;IACZ,WAAW,EAAE,CAAC,GAAG,SAAS,CAAC;CAC9B,GACD;IACI,IAAI,EAAE,SAAS,CAAC;IAChB,SAAS,EAAE,CAAC,CAAC;CAChB,GACD;IACI,IAAI,EAAE,OAAO,CAAC;IACd,WAAW,EAAE,CAAC,GAAG,SAAS,CAAC;CAC9B,GACD;IACI,IAAI,EAAE,QAAQ,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,CAAC,EAAE,CAAC;IAChB,YAAY,EAAE,CAAC,EAAE,CAAC;CACrB,GACD;IACI,IAAI,EAAE,OAAO,CAAC;IACd,YAAY,EAAE,CAAC,EAAE,CAAC;CACrB,CAAC;AAER;;;;;;;;;;GAUG;AACH,MAAM,WAAW,SAAS,CAAC,CAAC,CAAE,SAAQ,SAAS,CAAC,CAAC,EAAE,CAAC;IAChD;;;;;;;OAOG;IACH,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,GAAG,CAAC,GAAG,SAAS,CAAC;IAE9C;;;;;OAKG;IACH,IAAI,CAAC,IAAI,EAAE,CAAC,GAAG,IAAI,CAAC;IAEpB;;;;;;OAMG;IACH,GAAG,IAAI,CAAC,GAAG,SAAS,CAAC;IAErB;;;;;OAKG;IACH,OAAO,CAAC,IAAI,EAAE,CAAC,GAAG,IAAI,CAAC;IAEvB;;;;;;OAMG;IACH,KAAK,IAAI,CAAC,GAAG,SAAS,CAAC;IAEvB;;;;;;;;OAQG;IACH,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,GAAG,QAAQ,EAAE,CAAC,EAAE,GAAG,CAAC,EAAE,CAAC;IAElE;;;;;OAKG;IACH,KAAK,IAAI,CAAC,EAAE,CAAC;IAEb;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;;;OAIG;IACH,WAAW,EAAE,SAAS,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC;CAC9C;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,KAAK,CAAC,CAAC,EAAE,OAAO,CAAC,EAAE,CAAC,EAAE,GAAG,SAAS,CAAC,CAAC,CAAC,CAEpD"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { FlowState } from '../sync/flowState';
|
|
1
|
+
import { FlowState } from '../sync/flowState.js';
|
|
2
2
|
/**
|
|
3
3
|
* Discriminated union representing all possible map mutation operations.
|
|
4
4
|
*
|
|
@@ -76,7 +76,8 @@ export interface FlowMap<K, V> extends FlowState<Map<K, V>> {
|
|
|
76
76
|
clear(): Map<K, V>;
|
|
77
77
|
/**
|
|
78
78
|
* Reactive state containing the last mutation operation performed on the map.
|
|
79
|
-
*
|
|
79
|
+
* `.subscribe()` invokes its callback once per mutation (including several in the same tick).
|
|
80
|
+
* `get()` / `pick()` expose only the latest action snapshot.
|
|
80
81
|
*/
|
|
81
82
|
$lastAction: FlowState<FlowMapAction<K, V>>;
|
|
82
83
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowMap.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/collections/flowMap.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowMap.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/collections/flowMap.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEtD;;;;;;;;;GASG;AACH,MAAM,MAAM,aAAa,CAAC,CAAC,EAAE,CAAC,IACxB;IACI,IAAI,EAAE,KAAK,CAAC;IACZ,MAAM,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAClB,UAAU,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;CACzB,GACD;IACI,IAAI,EAAE,KAAK,CAAC;IACZ,GAAG,EAAE,CAAC,CAAC;IACP,UAAU,EAAE,CAAC,CAAC;CACjB,GACD;IACI,IAAI,EAAE,QAAQ,CAAC;IACf,GAAG,EAAE,CAAC,CAAC;IACP,QAAQ,EAAE,CAAC,CAAC;IACZ,YAAY,EAAE,CAAC,CAAC;CACnB,GACD;IACI,IAAI,EAAE,QAAQ,CAAC;IACf,GAAG,EAAE,CAAC,CAAC;IACP,YAAY,EAAE,CAAC,CAAC;CACnB,GACD;IACI,IAAI,EAAE,OAAO,CAAC;IACd,UAAU,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;CACzB,CAAC;AAER;;;;;;;;;;GAUG;AACH,MAAM,WAAW,OAAO,CAAC,CAAC,EAAE,CAAC,CAAE,SAAQ,SAAS,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IACvD;;;;;;OAMG;IACH,MAAM,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC;IAElB;;;;;;;OAOG;IACH,MAAM,CAAC,GAAG,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,GAAG,SAAS,CAAC;IAExC;;;;;;OAMG;IACH,GAAG,CAAC,GAAG,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,IAAI,CAAC;IAE5B;;;;;OAKG;IACH,KAAK,IAAI,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAEnB;;;;OAIG;IACH,WAAW,EAAE,SAAS,CAAC,aAAa,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;CAC/C;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,GAAG,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,CAAC,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,EAAE,CAAC,CAAC,CAK5G"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './flowArray';
|
|
2
|
-
export * from './flowMap';
|
|
1
|
+
export * from './flowArray.js';
|
|
2
|
+
export * from './flowMap.js';
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/collections/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/collections/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { FlowDisposable } from '../base/flowDisposable';
|
|
2
|
-
import { FlowDataTracker, FlowOnDataListener, FlowOnErrorListener, FlowOnPendingListener } from '../base/flowSubscribable';
|
|
1
|
+
import { FlowDisposable } from '../base/flowDisposable.js';
|
|
2
|
+
import { FlowDataTracker, FlowOnDataListener, FlowOnErrorListener, FlowOnPendingListener } from '../base/flowSubscribable.js';
|
|
3
3
|
/**
|
|
4
4
|
* Handle to a reactive effect that automatically tracks dependencies and re-executes when they change.
|
|
5
5
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowEffect.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/flowEffect.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowEffect.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/flowEffect.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,KAAK,EACR,eAAe,EACf,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACxB,MAAM,6BAA6B,CAAC;AAErC;;;;;;;GAOG;AACH,MAAM,WAAW,UAAW,SAAQ,cAAc;CAAG;AAErD;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,SAAS,CAAC,CAAC,EACvB,IAAI,EAAE,eAAe,CAAC,CAAC,CAAC,EACxB,MAAM,EAAE,kBAAkB,CAAC,CAAC,CAAC,EAC7B,OAAO,CAAC,EAAE,mBAAmB,EAC7B,SAAS,CAAC,EAAE,qBAAqB,GAClC,UAAU,CAEZ"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowSignal.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/flowSignal.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowSignal.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/flowSignal.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAEhE;;;;;;;;GAQG;AACH,MAAM,WAAW,UAAW,SAAQ,cAAc,CAAC,IAAI,CAAC;CAAG;AAE3D;;;;;;;;;;GAUG;AACH,wBAAgB,MAAM,IAAI,UAAU,CAEnC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { FlowObservable } from '../base/flowObservable';
|
|
2
|
-
import { FlowTracker } from '../base/flowTracker';
|
|
1
|
+
import { FlowObservable } from '../base/flowObservable.js';
|
|
2
|
+
import { FlowTracker } from '../base/flowTracker.js';
|
|
3
3
|
/**
|
|
4
4
|
* Base interface for reactive values that can be read synchronously or asynchronously.
|
|
5
5
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowValue.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/flowValue.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowValue.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/flowValue.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAE1D;;;;;;;;;GASG;AACH,MAAM,WAAW,SAAS,CAAC,CAAC,CAAE,SAAQ,cAAc,CAAC,CAAC,CAAC;IACnD;;;;;;;;;OASG;IACH,GAAG,CAAC,OAAO,EAAE,WAAW,GAAG,CAAC,CAAC;IAE7B;;;;;;;;OAQG;IACH,IAAI,IAAI,OAAO,CAAC,CAAC,CAAC,CAAC;CACtB"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export * from './async';
|
|
2
|
-
export * from './collections';
|
|
3
|
-
export * from './flowEffect';
|
|
4
|
-
export * from './flowSignal';
|
|
5
|
-
export * from './flowValue';
|
|
6
|
-
export * from './sync';
|
|
7
|
-
export * from './utils';
|
|
1
|
+
export * from './async/index.js';
|
|
2
|
+
export * from './collections/index.js';
|
|
3
|
+
export * from './flowEffect.js';
|
|
4
|
+
export * from './flowSignal.js';
|
|
5
|
+
export * from './flowValue.js';
|
|
6
|
+
export * from './sync/index.js';
|
|
7
|
+
export * from './utils.js';
|
|
8
8
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { FlowValue } from '../flowValue';
|
|
2
|
-
import { NotPromise } from '../utils';
|
|
1
|
+
import { FlowValue } from '../flowValue.js';
|
|
2
|
+
import { NotPromise } from '../utils.js';
|
|
3
3
|
/** Function that initializes a value. */
|
|
4
4
|
export type InitFunction<T> = () => NotPromise<T>;
|
|
5
5
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowConstant.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/flowConstant.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowConstant.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/flowConstant.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C,yCAAyC;AACzC,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI,MAAM,UAAU,CAAC,CAAC,CAAC,CAAC;AAElD;;;;;;;;GAQG;AACH,MAAM,WAAW,YAAY,CAAC,CAAC,CAAE,SAAQ,SAAS,CAAC,CAAC,CAAC;CAAG;AAExD;;;;;;;;;;;GAWG;AACH,wBAAgB,QAAQ,CAAC,CAAC,EAAE,WAAW,EAAE,YAAY,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC,CAAC,CAAC,CAEzE"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FlowTracker } from '../../base/flowTracker';
|
|
2
|
-
import { FlowValue } from '../flowValue';
|
|
3
|
-
import { NotPromise } from '../utils';
|
|
1
|
+
import { FlowTracker } from '../../base/flowTracker.js';
|
|
2
|
+
import { FlowValue } from '../flowValue.js';
|
|
3
|
+
import { NotPromise } from '../utils.js';
|
|
4
4
|
/** Function that derives a value from dependencies and optionally the previous value. */
|
|
5
5
|
export type DerivationFunction<T> = (tracker: FlowTracker, previous?: NotPromise<T> | undefined) => NotPromise<T>;
|
|
6
6
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowDerivation.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/flowDerivation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowDerivation.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/flowDerivation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AAC7D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C,yFAAyF;AACzF,MAAM,MAAM,kBAAkB,CAAC,CAAC,IAAI,CAAC,OAAO,EAAE,WAAW,EAAE,QAAQ,CAAC,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,SAAS,KAAK,UAAU,CAAC,CAAC,CAAC,CAAC;AAElH;;;;;;;;;GASG;AACH,MAAM,WAAW,cAAc,CAAC,CAAC,CAAE,SAAQ,SAAS,CAAC,CAAC,CAAC;IACnD;;OAEG;IACH,OAAO,IAAI,IAAI,CAAC;CACnB;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,UAAU,CAAC,CAAC,EAAE,OAAO,EAAE,kBAAkB,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAE/E"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FlowValue } from '../flowValue';
|
|
2
|
-
import { NotPromise } from '../utils';
|
|
3
|
-
import { InitFunction } from './flowConstant';
|
|
1
|
+
import { FlowValue } from '../flowValue.js';
|
|
2
|
+
import { NotPromise } from '../utils.js';
|
|
3
|
+
import { InitFunction } from './flowConstant.js';
|
|
4
4
|
/** Function that updates a value based on the previous value. */
|
|
5
5
|
export type UpdateFunction<T> = (previous: NotPromise<T> | undefined) => NotPromise<T>;
|
|
6
6
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowState.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/flowState.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowState.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/flowState.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAC9C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEtD,iEAAiE;AACjE,MAAM,MAAM,cAAc,CAAC,CAAC,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,SAAS,KAAK,UAAU,CAAC,CAAC,CAAC,CAAC;AAEvF;;;;;;;;GAQG;AACH,MAAM,WAAW,SAAS,CAAC,CAAC,CAAE,SAAQ,SAAS,CAAC,CAAC,CAAC;IAC9C;;;;;OAKG;IACH,GAAG,CAAC,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC;IAChC,GAAG,CAAC,OAAO,EAAE,cAAc,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC;CACzC;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,KAAK,CAAC,CAAC,EAAE,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC;AAC7D,wBAAgB,KAAK,CAAC,CAAC,EAAE,WAAW,EAAE,YAAY,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { DerivationFunction, FlowDerivation } from './flowDerivation';
|
|
2
|
-
import { FlowState } from './flowState';
|
|
1
|
+
import { DerivationFunction, FlowDerivation } from './flowDerivation.js';
|
|
2
|
+
import { FlowState } from './flowState.js';
|
|
3
3
|
/**
|
|
4
4
|
* Writable reactive value that recomputes automatically when dependencies change, but can be manually overridden.
|
|
5
5
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowWritableDerivation.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/flowWritableDerivation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"flowWritableDerivation.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/flowWritableDerivation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAC9E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAEhD;;;;;;;;;GASG;AACH,MAAM,WAAW,sBAAsB,CAAC,CAAC,CAAE,SAAQ,SAAS,CAAC,CAAC,CAAC,EAAE,cAAc,CAAC,CAAC,CAAC;CAAG;AAErF;;;;;;;;;;;GAWG;AACH,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,OAAO,EAAE,kBAAkB,CAAC,CAAC,CAAC,GAAG,sBAAsB,CAAC,CAAC,CAAC,CAE/F"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export * from './flowConstant';
|
|
2
|
-
export * from './flowDerivation';
|
|
3
|
-
export * from './flowState';
|
|
4
|
-
export * from './flowWritableDerivation';
|
|
1
|
+
export * from './flowConstant.js';
|
|
2
|
+
export * from './flowDerivation.js';
|
|
3
|
+
export * from './flowState.js';
|
|
4
|
+
export * from './flowWritableDerivation.js';
|
|
5
5
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/api/nodes/sync/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,6BAA6B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../src/api/nodes/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAEhD;;;;;;;;GAQG;AACH,MAAM,MAAM,UAAU,CAAC,CAAC,IAAI,CAAC,SAAS,OAAO,CAAC,OAAO,CAAC,GAAG,KAAK,GAAG,CAAC,CAAC;AAEnE;;;;;;;;;GASG;AACH,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,KAAK,GAAG,SAAS,GAAG,SAAS,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"disposable.d.ts","sourceRoot":"","sources":["../../../src/base/disposable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"disposable.d.ts","sourceRoot":"","sources":["../../../src/base/disposable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAEtD;;;GAGG;AACH,qBAAa,UAAW,YAAW,cAAc;IAC7C,SAAS,CAAC,SAAS,UAAS;IAE5B,IAAI,QAAQ,IAAI,OAAO,CAEtB;IAED,OAAO,IAAI,IAAI;CAIlB"}
|
|
@@ -1,14 +1,35 @@
|
|
|
1
|
-
import { IObserver } from './observer';
|
|
1
|
+
import { IObserver } from './observer.js';
|
|
2
2
|
/**
|
|
3
3
|
* Global scheduler that batches and executes reactive computations asynchronously.
|
|
4
|
+
*
|
|
5
|
+
* Flush order: pending value nodes first, then effects (setTimeout(0)).
|
|
6
|
+
* Queues are index-drained so items appended mid-flush are not lost (see _drain).
|
|
4
7
|
*/
|
|
5
8
|
export declare class ExecutionStack {
|
|
9
|
+
private static readonly _MAX_FLUSH_STEPS;
|
|
6
10
|
private static readonly _pendingQueue;
|
|
7
11
|
private static readonly _effectQueue;
|
|
8
12
|
private static _executionScheduled?;
|
|
13
|
+
private static _coalesceResetScheduled;
|
|
14
|
+
/**
|
|
15
|
+
* True once the current synchronous call stack has finished and microtasks have started.
|
|
16
|
+
* EffectNode uses this to treat microtask notifications (e.g. async resolve) differently
|
|
17
|
+
* from coalesced sync-batch notifications.
|
|
18
|
+
*/
|
|
19
|
+
private static _pastSyncTurn;
|
|
20
|
+
/** @internal Used by EffectNode to distinguish sync-batch from microtask notifications. */
|
|
21
|
+
static get pastSyncTurn(): boolean;
|
|
22
|
+
/**
|
|
23
|
+
* @internal Runs after the current sync turn ends (queueMicrotask).
|
|
24
|
+
* Marks pastSyncTurn so the next coalesced effect notify can bump its epoch,
|
|
25
|
+
* and resets per-effect coalesce flags via onReset.
|
|
26
|
+
*/
|
|
27
|
+
static scheduleCoalesceReset(onReset: () => void): void;
|
|
9
28
|
static pushPending(node: IObserver): void;
|
|
10
29
|
static pushEffect(effect: IObserver): void;
|
|
30
|
+
private static _beginSyncTurn;
|
|
11
31
|
private static _scheduleExecution;
|
|
32
|
+
private static _drain;
|
|
12
33
|
private static _execute;
|
|
13
34
|
}
|
|
14
35
|
//# sourceMappingURL=executionStack.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"executionStack.d.ts","sourceRoot":"","sources":["../../../src/base/executionStack.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"executionStack.d.ts","sourceRoot":"","sources":["../../../src/base/executionStack.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE/C;;;;;GAKG;AACH,qBAAa,cAAc;IACvB,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,gBAAgB,CAAU;IAClD,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,aAAa,CAAmB;IACxD,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,YAAY,CAAmB;IACvD,OAAO,CAAC,MAAM,CAAC,mBAAmB,CAAC,CAAgB;IACnD,OAAO,CAAC,MAAM,CAAC,uBAAuB,CAAS;IAC/C;;;;OAIG;IACH,OAAO,CAAC,MAAM,CAAC,aAAa,CAAS;IAErC,2FAA2F;IAC3F,MAAM,KAAK,YAAY,IAAI,OAAO,CAEjC;IAED;;;;OAIG;IACH,MAAM,CAAC,qBAAqB,CAAC,OAAO,EAAE,MAAM,IAAI,GAAG,IAAI;IAUvD,MAAM,CAAC,WAAW,CAAC,IAAI,EAAE,SAAS,GAAG,IAAI;IAMzC,MAAM,CAAC,UAAU,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI;IAM1C,OAAO,CAAC,MAAM,CAAC,cAAc;IAK7B,OAAO,CAAC,MAAM,CAAC,kBAAkB;IAWjC,OAAO,CAAC,MAAM,CAAC,MAAM;IAerB,OAAO,CAAC,MAAM,CAAC,QAAQ;CAI1B"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export * from './disposable';
|
|
2
|
-
export * from './executionStack';
|
|
3
|
-
export * from './node';
|
|
4
|
-
export * from './observable';
|
|
5
|
-
export * from './observer';
|
|
1
|
+
export * from './disposable.js';
|
|
2
|
+
export * from './executionStack.js';
|
|
3
|
+
export * from './node.js';
|
|
4
|
+
export * from './observable.js';
|
|
5
|
+
export * from './observer.js';
|
|
6
6
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/base/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/base/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,qBAAqB,CAAC;AACpC,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { FlowEffect, FlowOnDataListener, FlowOnErrorListener, FlowOnPendingListener, FlowTracker } from '../api';
|
|
2
|
-
import { Disposable } from './disposable';
|
|
3
|
-
import { IObservable, ObservableStatus } from './observable';
|
|
4
|
-
import { IObserver } from './observer';
|
|
1
|
+
import { FlowEffect, FlowOnDataListener, FlowOnErrorListener, FlowOnPendingListener, FlowTracker } from '../api/index.js';
|
|
2
|
+
import { Disposable } from './disposable.js';
|
|
3
|
+
import { IObservable, ObservableStatus } from './observable.js';
|
|
4
|
+
import { IObserver } from './observer.js';
|
|
5
5
|
/**
|
|
6
6
|
* Base implementation for reactive nodes that propagate changes through the dependency graph.
|
|
7
7
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"node.d.ts","sourceRoot":"","sources":["../../../src/base/node.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"node.d.ts","sourceRoot":"","sources":["../../../src/base/node.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACR,UAAU,EACV,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACrB,WAAW,EACd,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,KAAK,EAAE,WAAW,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACrE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE/C;;GAEG;AACH,8BAAsB,IAAI,CAAC,CAAC,CAAE,SAAQ,UAAW,YAAW,WAAW,CAAC,CAAC,CAAC,EAAE,SAAS;IACjF,OAAO,CAAC,aAAa,CAAmC;IACxD,OAAO,CAAC,WAAW,CAAwB;IAC3C,SAAS,CAAC,OAAO,EAAE,gBAAgB,CAAc;IAEjD,IAAI,MAAM,IAAI,gBAAgB,CAG7B;IAED,IAAI,MAAM,CAAC,MAAM,EAAE,gBAAgB,EAGlC;IAED,kBAAkB,CAAC,UAAU,EAAE,WAAW,CAAC,OAAO,CAAC,GAAG,IAAI;IAM1D,oBAAoB,CAAC,UAAU,EAAE,WAAW,CAAC,OAAO,CAAC,GAAG,IAAI;IAM5D,iBAAiB,IAAI,IAAI;IAQzB,iBAAiB,CAAC,SAAS,EAAE,SAAS,GAAG,IAAI;IAK7C,mBAAmB,CAAC,SAAS,EAAE,SAAS,GAAG,IAAI;IAK/C,gBAAgB,IAAI,IAAI;IAOxB,KAAK,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI;IAKjC,OAAO,IAAI,IAAI;IAKf,MAAM,IAAI,IAAI;IAOL,OAAO,IAAI,IAAI;IAaxB,QAAQ,CAAC,OAAO,IAAI,IAAI;IAExB,QAAQ,CAAC,SAAS,CACd,OAAO,EAAE,kBAAkB,CAAC,CAAC,CAAC,EAC9B,OAAO,CAAC,EAAE,mBAAmB,EAC7B,SAAS,CAAC,EAAE,qBAAqB,GAClC,UAAU;CAChB"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FlowEffect, FlowObservable, FlowOnDataListener, FlowOnErrorListener, FlowOnPendingListener, FlowTracker } from '../api';
|
|
2
|
-
import { Disposable } from './disposable';
|
|
3
|
-
import { IObserver } from './observer';
|
|
1
|
+
import { FlowEffect, FlowObservable, FlowOnDataListener, FlowOnErrorListener, FlowOnPendingListener, FlowTracker } from '../api/index.js';
|
|
2
|
+
import { Disposable } from './disposable.js';
|
|
3
|
+
import { IObserver } from './observer.js';
|
|
4
4
|
/**
|
|
5
5
|
* Status of an observable: resolved (has value), pending (async in progress), error (failed), or dirty (needs recomputation).
|
|
6
6
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"observable.d.ts","sourceRoot":"","sources":["../../../src/base/observable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACR,UAAU,EACV,cAAc,EACd,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACrB,WAAW,EACd,MAAM,
|
|
1
|
+
{"version":3,"file":"observable.d.ts","sourceRoot":"","sources":["../../../src/base/observable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACR,UAAU,EACV,cAAc,EACd,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACrB,WAAW,EACd,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE/C;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG,UAAU,GAAG,SAAS,GAAG,OAAO,GAAG,OAAO,CAAC;AAE1E;;GAEG;AACH,MAAM,WAAW,WAAW,CAAC,CAAC,CAAE,SAAQ,cAAc,CAAC,CAAC,CAAC;IACrD,IAAI,MAAM,IAAI,gBAAgB,CAAC;IAC/B,IAAI,MAAM,CAAC,MAAM,EAAE,gBAAgB,EAAE;IACrC,iBAAiB,CAAC,SAAS,EAAE,SAAS,GAAG,IAAI,CAAC;IAC9C,mBAAmB,CAAC,SAAS,EAAE,SAAS,GAAG,IAAI,CAAC;IAChD,gBAAgB,IAAI,IAAI,CAAC;IACzB,SAAS,CACL,OAAO,EAAE,kBAAkB,CAAC,CAAC,CAAC,EAC9B,OAAO,CAAC,EAAE,mBAAmB,EAC7B,SAAS,CAAC,EAAE,qBAAqB,GAClC,UAAU,CAAC;CACjB;AAED;;GAEG;AACH,8BAAsB,UAAU,CAAC,CAAC,CAAE,SAAQ,UAAW,YAAW,WAAW,CAAC,CAAC,CAAC;IAC5E,OAAO,CAAC,WAAW,CAAwB;IAC3C,SAAS,CAAC,OAAO,EAAE,gBAAgB,CAAc;IAEjD,IAAI,MAAM,IAAI,gBAAgB,CAG7B;IAED,IAAI,MAAM,CAAC,MAAM,EAAE,gBAAgB,EAGlC;IAED,iBAAiB,CAAC,SAAS,EAAE,SAAS,GAAG,IAAI;IAK7C,mBAAmB,CAAC,SAAS,EAAE,SAAS,GAAG,IAAI;IAK/C,gBAAgB,IAAI,IAAI;IAOxB,KAAK,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI;IAKjC,OAAO,IAAI,IAAI;IAKN,OAAO,IAAI,IAAI;IAUxB,QAAQ,CAAC,SAAS,CACd,OAAO,EAAE,kBAAkB,CAAC,CAAC,CAAC,EAC9B,OAAO,CAAC,EAAE,mBAAmB,EAC7B,SAAS,CAAC,EAAE,qBAAqB,GAClC,UAAU;CAChB"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Disposable } from './disposable';
|
|
2
|
-
import { IObservable } from './observable';
|
|
1
|
+
import { Disposable } from './disposable.js';
|
|
2
|
+
import { IObservable } from './observable.js';
|
|
3
3
|
/**
|
|
4
4
|
* Internal interface for reactive computations that track dependencies and respond to changes.
|
|
5
5
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"observer.d.ts","sourceRoot":"","sources":["../../../src/base/observer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"observer.d.ts","sourceRoot":"","sources":["../../../src/base/observer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD;;GAEG;AACH,MAAM,WAAW,SAAS;IACtB,kBAAkB,CAAC,UAAU,EAAE,WAAW,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC;IAC3D,oBAAoB,CAAC,UAAU,EAAE,WAAW,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC;IAC7D,iBAAiB,IAAI,IAAI,CAAC;IAC1B,MAAM,IAAI,IAAI,CAAC;IACf,OAAO,IAAI,IAAI,CAAC;CACnB;AAED;;GAEG;AACH,8BAAsB,QAAS,SAAQ,UAAW,YAAW,SAAS;IAClE,OAAO,CAAC,aAAa,CAAmC;IAExD,kBAAkB,CAAC,UAAU,EAAE,WAAW,CAAC,OAAO,CAAC,GAAG,IAAI;IAM1D,oBAAoB,CAAC,UAAU,EAAE,WAAW,CAAC,OAAO,CAAC,GAAG,IAAI;IAM5D,iBAAiB,IAAI,IAAI;IAQhB,OAAO,IAAI,IAAI;IAQxB,QAAQ,CAAC,MAAM,IAAI,IAAI;IACvB,QAAQ,CAAC,OAAO,IAAI,IAAI;CAC3B"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './solid';
|
|
1
|
+
export * from './solid.js';
|
|
2
2
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/converters/index.ts"],"names":[],"mappings":"AAAA,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/converters/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Resource } from 'solid-js';
|
|
2
|
-
import {
|
|
2
|
+
import { FlowTracker, FlowValue, NotPromise } from '../api/index.js';
|
|
3
3
|
/**
|
|
4
|
-
* Converts a PicoFlow
|
|
4
|
+
* Converts a PicoFlow value or getter function into a SolidJS resource.
|
|
5
5
|
*
|
|
6
|
-
* @param flow - The
|
|
6
|
+
* @param flow - The FlowValue or getter function to convert.
|
|
7
7
|
* @returns A SolidJS Resource that wraps the value or computation.
|
|
8
8
|
*
|
|
9
9
|
* @remarks
|
|
@@ -12,12 +12,16 @@ import { FlowObservable, FlowTracker, NotPromise } from '../api';
|
|
|
12
12
|
* SolidJS Resource, which can handle both synchronous and asynchronous values seamlessly.
|
|
13
13
|
*
|
|
14
14
|
* The conversion works with:
|
|
15
|
-
* - **
|
|
15
|
+
* - **FlowValue**: PicoFlow primitives that expose a readable value (e.g. from `state()`, `derivation()`, `stateAsync()`, `derivationAsync()`, `array()`, `map()`)
|
|
16
16
|
* - **Getter functions**: Computation functions that use a FlowTracker to access reactive values
|
|
17
17
|
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
18
|
+
* Signals are not supported: they carry no value to expose through a Resource. Use a getter that reads the reactive values you need instead.
|
|
19
|
+
*
|
|
20
|
+
* The created Resource automatically subscribes to the PicoFlow value and updates
|
|
21
|
+
* when it changes. The subscription is properly cleaned up when the Solid
|
|
22
|
+
* component unmounts. When converting a getter function, the internal derivation
|
|
23
|
+
* node is also disposed on unmount. User-owned FlowValue instances passed directly
|
|
24
|
+
* to `from()` are not disposed.
|
|
21
25
|
*
|
|
22
26
|
* @example
|
|
23
27
|
* ```typescript
|
|
@@ -41,6 +45,6 @@ import { FlowObservable, FlowTracker, NotPromise } from '../api';
|
|
|
41
45
|
*
|
|
42
46
|
* @public
|
|
43
47
|
*/
|
|
44
|
-
export declare function from<T>(flow:
|
|
48
|
+
export declare function from<T>(flow: FlowValue<T>): Resource<T>;
|
|
45
49
|
export declare function from<T>(flow: (t: FlowTracker) => NotPromise<T>): Resource<T>;
|
|
46
50
|
//# sourceMappingURL=solid.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"solid.d.ts","sourceRoot":"","sources":["../../../src/converters/solid.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoD,KAAK,QAAQ,EAAwB,MAAM,UAAU,CAAC;AACjH,OAAO,EAAmB,KAAK,
|
|
1
|
+
{"version":3,"file":"solid.d.ts","sourceRoot":"","sources":["../../../src/converters/solid.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoD,KAAK,QAAQ,EAAwB,MAAM,UAAU,CAAC;AACjH,OAAO,EAAmB,KAAK,WAAW,EAAE,KAAK,SAAS,EAAE,KAAK,UAAU,EAAa,MAAM,iBAAiB,CAAC;AAoEhH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4CG;AACH,wBAAgB,IAAI,CAAC,CAAC,EAAE,IAAI,EAAE,SAAS,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;AACzD,wBAAgB,IAAI,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE,WAAW,KAAK,UAAU,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC"}
|