You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The "ReactiveCommand" namespace makes it difficult to use the ReactiveCommand.CreateFromTask method used in existing code.
for example
using ReactiveCommand.SourceGenerator.Attributes;
using ReactiveUI;
using System.Reactive;
namespace MyNamespace
{
public partial class MyViewModel : ReactiveObject
{
private ReactiveCommand<Unit, Unit> MyCommand;
public MyViewModel() {
InitializeCommands();
MyCommand = ReactiveCommand.CreateFromTask(DoSomething); //error
}
private async Task DoSomething() {
Console.WriteLine("Something!");
}
[ReactiveCommand]
public void DoStuff()
{
Console.WriteLine("Stuff!");
}
}
}
need to add the namespace to all existing command generation code. like this MyCommand = ReactiveUI.ReactiveCommand.CreateFromTask(DoSomething);
This is boring to everyone.
I'm hoping to change the ReactiveCommand.SourceGenerator namespace a bit.
The text was updated successfully, but these errors were encountered:
neominky
added a commit
to neominky/ReactiveCommand.SourceGenerator
that referenced
this issue
Apr 5, 2024
The "ReactiveCommand" namespace makes it difficult to use the ReactiveCommand.CreateFromTask method used in existing code.
for example
need to add the namespace to all existing command generation code. like this
MyCommand = ReactiveUI.ReactiveCommand.CreateFromTask(DoSomething);
This is boring to everyone.
I'm hoping to change the ReactiveCommand.SourceGenerator namespace a bit.
The text was updated successfully, but these errors were encountered: