Last active
August 29, 2018 17:44
-
-
Save EdCharbeneau/e8d156257b2f84ee91ac3c6a8785b51a to your computer and use it in GitHub Desktop.
Working with the Blazor JavaScript Interop
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Microsoft.JSInterop; | |
public class ExampleJsInterop | |
{ | |
public static Task<T> MethodName(TArgs args) | |
{ | |
// Implemented in exampleJsInterop.js | |
return JSRuntime.Current.InvokeAsync<T>("scope.jsMethod", args); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment