Update Blazor EventCallback example (#18802)

pull/18806/head
Luke Latham 2020-06-14 11:32:38 -05:00 committed by GitHub
parent 2d32ec6eb2
commit 6f8db9a59b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -173,7 +173,7 @@ When the button is selected in the `ChildComponent`:
Invoke an <xref:Microsoft.AspNetCore.Components.EventCallback> or <xref:Microsoft.AspNetCore.Components.EventCallback%601> with <xref:Microsoft.AspNetCore.Components.EventCallback.InvokeAsync%2A> and await the <xref:System.Threading.Tasks.Task>:
```csharp
await callback.InvokeAsync(arg);
await OnClickCallback.InvokeAsync(arg);
```
Use <xref:Microsoft.AspNetCore.Components.EventCallback> and <xref:Microsoft.AspNetCore.Components.EventCallback%601> for event handling and binding component parameters.