Skip to content

Commit

Permalink
fix(rx-stateful): keepValueOnRefresh defaults now to false
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelbe812 committed Jul 7, 2023
1 parent 2012f8e commit e20c605
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion libs/rx-stateful/src/lib/rx-stateful$.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export function rxStateful$<T, E = unknown>(
): RxStateful<T, E> {
const error$$ = new Subject<RxStatefulWithError<T, E>>();
const mergedConfig: RxStatefulConfig<T,E> = {
keepValueOnRefresh: true,
keepValueOnRefresh: false,
keepErrorOnRefresh: false,
...config,
};
Expand Down
2 changes: 1 addition & 1 deletion libs/rx-stateful/src/lib/types/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export interface RxStatefulConfig<T, E> {
refreshTrigger$?: Subject<any>;
/**
* Define if the value should be kept on refresh or reset to null
* @default true
* @default false
*/
keepValueOnRefresh?: boolean;
accumulationFn?: RxStatefulAccumulationFn<T, E>;
Expand Down

0 comments on commit e20c605

Please sign in to comment.