-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
@ngrx/data - mergeQuerySet does not use PreserveChanges strategy #2368
Comments
Full chain following the source code: mergeQuerySet Where applyCollectionReducer is run for each entityName with entityOp UPSERT_MANY + PreserveChanges is passed in action The problem with this is that in
I'm generally curious if a refactor where we keep |
within |
Minimal reproduction of the bug/regression with instructions:
see
mergePreserveChanges()
inapp.component.ts
in this stackblitzafter some setup the state (1 x added, 1 x updated, 1 x deleted) is:
I'm dispatching a
mergeQuerySet
withMergeStrategy.PreserveChanges
strategyHere I've updated the power to -1:
Expected behavior:
Reference https://ngrx.io/guide/data/entity-change-tracker#merge-strategies
Expected state:
Actual state:
Versions of NgRx, Angular, Node, affected browser(s) and operating system(s):
ngrx 8.6.0
angular 8
Other information:
I'll look through source and see if I can figure out the cause.
I would be willing to submit a PR to fix this issue
[x] Yes (Assistance is provided if you need help submitting a pull request)
[ ] No
The text was updated successfully, but these errors were encountered: