I'm following the sample that given from the official GitHub page about using ReactiveUI.ReactiveCommand below. (ReactiveUI v8.0.1) github link
public class MainViewModel : ReactiveObject
{
public ReactiveCommand ParameterlessCommand { get; }
public MainViewModel()
{
ParameterlessCommand = ReactiveCommand.Create(Parameterless);
}
private void Parameterless()
{
}
}
The errors occur when I use this implementation with the ReactiveUI v13.0.38
How can I use the command pattern in this MVVM code sample with ReactiveUI v13.0.38?
ReactiveCommand
class which implements ICommand
interface is a generic type.
// Unit is used for void - no input and output, so double Unit
public ReactiveCommand<Unit, Unit> ParameterlessCommand { get; }
// assigning
ParameterlessCommand = ReactiveCommand.Create(Parameterless);