Skip to content

Commit e4a3bdd

Browse files
committed
Update Documentation
1 parent fac0227 commit e4a3bdd

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

README.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ ReactiveUI Source Generators automatically generate ReactiveUI objects to stream
1616
- `[ObservableAsProperty(PropertyName = "ReadOnlyPropertyName")]`
1717
- `[ReactiveCommand]`
1818
- `[ReactiveCommand(CanExecute = nameof(IObservableBoolName))]` with CanExecute
19+
- `[ReactiveCommand(OutputScheduler = "RxApp.MainThreadScheduler")]` using a ReactiveUI Scheduler
20+
- `[ReactiveCommand(OutputScheduler = nameof(_isheduler))]` using a Scheduler defined in the class
1921
- `[ReactiveCommand][property: AttributeToAddToCommand]` with Attribute passthrough
2022
- `[IViewFor(nameof(ViewModelName))]`
2123
- `[RoutedControlHost("YourNameSpace.CustomControl")]`
@@ -411,6 +413,30 @@ public partial class MyReactiveClass
411413
}
412414
```
413415

416+
### Usage ReactiveCommand with ReactiveUI OutputScheduler
417+
```csharp
418+
using ReactiveUI.SourceGenerators;
419+
420+
public partial class MyReactiveClass
421+
{
422+
[ReactiveCommand(OutputScheduler = "RxApp.MainThreadScheduler")]
423+
private void Execute() { }
424+
}
425+
```
426+
427+
### Usage ReactiveCommand with custom OutputScheduler
428+
```csharp
429+
using ReactiveUI.SourceGenerators;
430+
431+
public partial class MyReactiveClass
432+
{
433+
private IScheduler _customScheduler = new TestScheduler();
434+
435+
[ReactiveCommand(OutputScheduler = nameof(_customScheduler))]
436+
private void Execute() { }
437+
}
438+
```
439+
414440
## Usage IViewFor `[IViewFor(nameof(ViewModelName))]`
415441

416442
### IViewFor usage

0 commit comments

Comments
 (0)