Unsubscription support for commands
TimofeyBurak opened this issue · 0 comments
TimofeyBurak commented
Is your feature request related to a problem? Please describe.
Reinitialization of reusable cells, for example for UITableView on iOS, sometimes required also reinitialization of the button-click actions. Currently, we use SetCommand(ICommand) extension for that, which cannot be undone.
Describe the solution you'd like
It would be nice to be able to set commands in DoAttachBindings method, and clear it in DoDettachBindings method
Describe alternatives you've considered
Currently, the only alternative is to set command during cell initialization with lambda looking like this:
Button.SetCommand(() => ViewModel.ButtonCommand.Execute(null))
which is not really convenient