@rx-signals/store
Advanced tools
Comparing version 2.6.2-rc1 to 2.6.2
@@ -1,3 +0,8 @@ | ||
# 2.6.2 () | ||
# 2.6.2 (2021-09-07) | ||
### Fixes | ||
- EffectSuccess interface was missing in the index.ts | ||
- Docstring typos | ||
### Features | ||
@@ -4,0 +9,0 @@ |
@@ -50,3 +50,4 @@ "use strict"; | ||
store.addLazyBehavior(triggeredInputBehavior, store.getEventStream(triggeredInputEvent), null); | ||
// It is important to setup the combined observable as behavior, because a simple shareReplay (event with refCount) creates a memory leak!!! | ||
// It is important to setup the combined observable as behavior, | ||
// because a simple shareReplay (event with refCount) would create a memory leak!!! | ||
const combinedId = store_utils_1.getIdentifier(); | ||
@@ -53,0 +54,0 @@ store.addLazyBehavior(combinedId, rxjs_1.combineLatest([ |
@@ -88,8 +88,9 @@ import { Observable } from 'rxjs'; | ||
/** | ||
* This is interface specifies effect signal factories (extending signal factories). An effect signals factory is a signals factory | ||
* to generically handle sideeffects. Futhermore, they are implemeted as builders to allow for easy custom configuration. | ||
* This interface specifies effect signal factories (extending signal factories). An effect signals factory is a signals factory | ||
* to generically handle sideeffects (hence, an abstraction over sideeffects). Furthermore, they are implemeted as builders to | ||
* allow for easy custom configuration. | ||
* An effect signals factory fulfills the following requirements: | ||
* 1.) The produced CombinedEffectResult<InputType, ResultType> behavior must be lazy, hence, as long as it is not subscribed, | ||
* no effect will be triggered. | ||
* 2.) Unhandled effect errors are caught by the factory and dispatched as EffectError<InputType>. As subscription of the corresponding | ||
* 2.) Unhandled effect errors are caught by the factory and dispatched as EffectError<InputType>. A subscription of the corresponding | ||
* errors event stream will NOT subscribe the result behavior (see requirement 1). | ||
@@ -108,5 +109,5 @@ * 3.) In addition to the result behavior, also an event stream for EffectSuccess<InputType, ResultType> is provided. This is important | ||
* @property {function} withTrigger - returns a factory with TriggeredEffectSignalsType<InputType, ResultType>. In contrast to the factory without trigger, the resulting factory will pass input to the effect only if a corresponding trigger event is received (e.g. a save button has been clicked). | ||
* @property {function} withInitialResult - resturns a factory that provides an initial result in the result behavior. For more flexibility, instead of the result itself, this function takes a function providing the initial result as argument. | ||
* @property {function} withInitialResult - returns a factory that provides an initial result in the result behavior. For more flexibility, instead of the result itself, this function takes a function providing the initial result as argument. | ||
* @property {function} withEffectDebounce - returns a factory that uses the specified time to debounce the result effect. This is different from debouncing the input yourself! If you debounce the input yourself, then also the currentInput in the result behavior will be debounced (hence the whole result behavior will be debounced). In contrast, if you use this function, then only the result effect itself will be debounced. | ||
* @property {function} withCustomEffectInputEquals - by default, reference equals is used to make the effect input distinct. However, this functio will return a factory that uses the provided custom equals function instead. | ||
* @property {function} withCustomEffectInputEquals - by default, reference equals is used to make the effect input distinct. However, this function will return a factory that uses the provided custom equals function instead. | ||
*/ | ||
@@ -113,0 +114,0 @@ export interface EffectSignalsFactory<InputType, ResultType, SignalsType> extends SignalsFactory<SignalsType> { |
@@ -47,3 +47,4 @@ var __rest = (this && this.__rest) || function (s, e) { | ||
store.addLazyBehavior(triggeredInputBehavior, store.getEventStream(triggeredInputEvent), null); | ||
// It is important to setup the combined observable as behavior, because a simple shareReplay (event with refCount) creates a memory leak!!! | ||
// It is important to setup the combined observable as behavior, | ||
// because a simple shareReplay (event with refCount) would create a memory leak!!! | ||
const combinedId = getIdentifier(); | ||
@@ -50,0 +51,0 @@ store.addLazyBehavior(combinedId, combineLatest([ |
@@ -1,2 +0,2 @@ | ||
export { CombinedEffectResult, EffectError, EffectSignalsFactory, EffectSignalsType, EffectType, getEffectSignalsFactory, TriggeredEffectSignalsType, } from './effect-signals-factory'; | ||
export { CombinedEffectResult, EffectError, EffectSignalsFactory, EffectSignalsType, EffectSuccess, EffectType, getEffectSignalsFactory, TriggeredEffectSignalsType, } from './effect-signals-factory'; | ||
export { createSignalsFactory, MappedSignalsType, Signals, SignalsFactory, signalsFactoryBind, signalsFactoryMap, } from './signals-factory'; | ||
@@ -3,0 +3,0 @@ export { Store, TypedEvent } from './store'; |
{ | ||
"name": "@rx-signals/store", | ||
"version": "2.6.2-rc1", | ||
"version": "2.6.2", | ||
"description": "Reactive effects management with behaviors and event streams", | ||
@@ -5,0 +5,0 @@ "author": "Gerd Neudert", |
@@ -180,3 +180,4 @@ import { combineLatest, Observable, of, throwError } from 'rxjs'; | ||
// It is important to setup the combined observable as behavior, because a simple shareReplay (event with refCount) creates a memory leak!!! | ||
// It is important to setup the combined observable as behavior, | ||
// because a simple shareReplay (event with refCount) would create a memory leak!!! | ||
const combinedId = getIdentifier< | ||
@@ -315,8 +316,9 @@ [ | ||
/** | ||
* This is interface specifies effect signal factories (extending signal factories). An effect signals factory is a signals factory | ||
* to generically handle sideeffects. Futhermore, they are implemeted as builders to allow for easy custom configuration. | ||
* This interface specifies effect signal factories (extending signal factories). An effect signals factory is a signals factory | ||
* to generically handle sideeffects (hence, an abstraction over sideeffects). Furthermore, they are implemeted as builders to | ||
* allow for easy custom configuration. | ||
* An effect signals factory fulfills the following requirements: | ||
* 1.) The produced CombinedEffectResult<InputType, ResultType> behavior must be lazy, hence, as long as it is not subscribed, | ||
* no effect will be triggered. | ||
* 2.) Unhandled effect errors are caught by the factory and dispatched as EffectError<InputType>. As subscription of the corresponding | ||
* 2.) Unhandled effect errors are caught by the factory and dispatched as EffectError<InputType>. A subscription of the corresponding | ||
* errors event stream will NOT subscribe the result behavior (see requirement 1). | ||
@@ -335,5 +337,5 @@ * 3.) In addition to the result behavior, also an event stream for EffectSuccess<InputType, ResultType> is provided. This is important | ||
* @property {function} withTrigger - returns a factory with TriggeredEffectSignalsType<InputType, ResultType>. In contrast to the factory without trigger, the resulting factory will pass input to the effect only if a corresponding trigger event is received (e.g. a save button has been clicked). | ||
* @property {function} withInitialResult - resturns a factory that provides an initial result in the result behavior. For more flexibility, instead of the result itself, this function takes a function providing the initial result as argument. | ||
* @property {function} withInitialResult - returns a factory that provides an initial result in the result behavior. For more flexibility, instead of the result itself, this function takes a function providing the initial result as argument. | ||
* @property {function} withEffectDebounce - returns a factory that uses the specified time to debounce the result effect. This is different from debouncing the input yourself! If you debounce the input yourself, then also the currentInput in the result behavior will be debounced (hence the whole result behavior will be debounced). In contrast, if you use this function, then only the result effect itself will be debounced. | ||
* @property {function} withCustomEffectInputEquals - by default, reference equals is used to make the effect input distinct. However, this functio will return a factory that uses the provided custom equals function instead. | ||
* @property {function} withCustomEffectInputEquals - by default, reference equals is used to make the effect input distinct. However, this function will return a factory that uses the provided custom equals function instead. | ||
*/ | ||
@@ -340,0 +342,0 @@ export interface EffectSignalsFactory<InputType, ResultType, SignalsType> |
@@ -6,2 +6,3 @@ export { | ||
EffectSignalsType, | ||
EffectSuccess, | ||
EffectType, | ||
@@ -8,0 +9,0 @@ getEffectSignalsFactory, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
334806
5096
1