Odonno / ReduxSimple

Simple Stupid Redux Store using Reactive Extensions
http://www.nuget.org/packages/ReduxSimple/
MIT License
144 stars 20 forks source link

On function new() constraint does not play nicely with immutables #70

Closed kobi2294 closed 4 years ago

kobi2294 commented 4 years ago

When using ReduxSimple.Reducers.On methods, they all require TState that has a new() - default parameterless constructor. In my project, I am using immutable classes that have readonly properties and a constructor that takes all the properties as parameters, so there is no parameterless constructor. Why should this be a constraint?

Odonno commented 4 years ago

Hi @kobi2294 I think it may be a legacy constraint from the previous versions of ReduxSimple. I will fix that and let you know when the new version is available.

Odonno commented 4 years ago

The v3.0.1 will be available soon.