Closed GeorgeS2019 closed 2 years ago
@sps014
This is not urgent,
Imagine running BlazorBindGen in .NET interactive notebook through RazorLight
Possible to make @inject IJSRuntime JS works through RazorLight in RazorInteractive
The key is how to do in .NET interactive notebook.
@using Microsoft.JSInterop;
@inject IJSRuntime JS
The problem is that one needs to inherit the abstract class IJSRuntime
Here is an example
After that using RazorLight to inject the concrete IJSRUntime class.
This is obviously a simplication.
However, I find that interesting and the prospect of SHOWING blazorBindGen in .NET interactive for e.g. teaching
@sps014
This is not urgent,
Imagine running BlazorBindGen in .NET interactive notebook through RazorLight
Possible to make @inject IJSRuntime JS works through RazorLight in RazorInteractive
The key is how to do in .NET interactive notebook.
@using Microsoft.JSInterop; @inject IJSRuntime JS
The problem is that one needs to inherit the abstract class IJSRuntime
Here is an example
After that using RazorLight to inject the concrete IJSRUntime class.
This is obviously a simplication.
However, I find that interesting and the prospect of SHOWING blazorBindGen in .NET interactive for e.g. teaching
Microsoft has already built an alternative JS interop mechanics (to be released in NET 7 RCs). Also adding support of .NET Interactive is out of scope of this project, as one of my primary concerns before creating this project was performance, a lot of code need rewriting and I have to introduce some overhead as we can't directly plug a new IJSRuntime
implementation.
See .NET JavaScript interop on WebAssembly in this release note.
@sps014 Interested to get your view on that, perhaps in the discussion?
Ref1: [API Proposal]: JavaScript interop with [JSImport] and [JSExport] attributes and Roslyn
@sps014 Interested to get your view on that, perhaps in the discussion?
Ref1: [API Proposal]: JavaScript interop with [JSImport] and [JSExport] attributes and Roslyn
Haven't played with the API, will do in few weeks, then I can have some discussion.
@sps014 Have you had time to play with it?
Very curious what you think for the next version of this project :-)
@sps014
Any update, curious what is next for this project!
[API Proposal]: JavaScript interop with [JSImport] and [JSExport] attributes and Roslyn
@sps014
Any update, curious what is next for this project!
[API Proposal]: JavaScript interop with [JSImport] and [JSExport] attributes and Roslyn
The goal of the project is complete , most of scenarios are covered, that I planned, if any one has any suggestions that fits this project is more than welcome.
Discussion: Blazor Component with BlazorBindGen in .NET Interactive