DEV Community

Cover image for Interacting with JavaScript Objects using the new IJSObjectReference in Blazor
Niels Swimburger.NET ๐Ÿ”
Niels Swimburger.NET ๐Ÿ”

Posted on • Originally published at swimburger.net on

Interacting with JavaScript Objects using the new IJSObjectReference in Blazor

New API's to interact with JavaScript from .NET were added with the introduction of Blazor. Using these API's you can invoke JavaScript functions from .NET and .NET methods from JavaScript. This is also referred to as ' JavaScript interoperability'.

The JavaScript interoperability API's provided by Microsoft live under Microsoft.JSInterop namespace. These capabilities were showcased at a previous article: "Communicating between .NET and JavaScript in Blazor with in-browser samples".

Some additional API's have now been introduced with the release of .NET 5. One very important API in particular was introduced: IJSObjectReference.

Continue reading at swimburger.net

Top comments (0)