Little add-on re viable alternative: Silverlight could have been nice, hadn’t Microsoft fucked it up and implemented it as a Windows-only ActiveX control.
With .NET Core/.NET 5+ being open source and platform independent, that idea/concept could be revisited. A trimmed down .NET framework in a sandbox with proper DOM integration would be a massive upgrade over all the JavaScript garbage.
That only helps if there’s a viable FOSS toolchain for .NET, including editor and debugger, which as far as I know is still proprietary. Using proprietary development tools is to be avoided if at all possible, not only because of principles but also because they will create problems that you are powerless to solve.
There is the fully open source debugger from Samsung, the Red Hat derivate/extension for eclipse and others are in the works. I’m happily debugging .NET applications with JetBrains’ debugger on linux. One tool by Microsoft for the ecosystem not being open source, doesn’t change .NET (Core/5+) being open source. Embedding a stripped down .NET Framework in browsers as a replacement/alternative to JavaScript, even if not required, would likely lead to the development of one or more new debuggers anyways, to have an in-browser development experience similar to how it is now with JavaScript.