Closed nartc closed 3 years ago
Hi, thanks for raising the issue.
Do you have a reproduction to share? I tried it (in stackblitz) with the ngrx demo app, and it seems to work here. (https://stackblitz.com/edit/angular-vxzacg?file=src/app/slide-toggle.component.ts)
It doesn't need the immerReducer
, because it uses the updater
method to update the state.
setState
is added to ImmerComponentStore
to override the typings so it doesn't require you to return the state.
Here's the Stackblitz with the issue: https://stackblitz.com/edit/angular-ivy-immer-component-store-issue?file=src/app/store.ts
Thanks @nartc ! That's weird... when I download the sb locally it seems to build... Anyways, ngrx-immer (v0.0.4) is now build with ng-packagr so the issue should be resolved - at least it seems to be on my end 😀 Feel free to re-open if that's not the case.
Getting this error with
ImmerComponentStore
as soon as startup.Also, are we missing the use of
immerReducer
here? https://github.com/timdeschryver/ngrx-immer/blob/main/src/component-store/index.ts#L26