News

Visual Studio Code Gears Up for Blazor

Microsoft is preparing its open source Visual Studio Code editor to support Blazor, the company's experimental technology for using languages such as C# for Web programming, which is currently dominated by JavaScript.

The promise of such a capability is creating a lot of buzz because Web coding using languages other than JavaScript would open up huge opportunities for .NET-centric and other developers.

Microsoft's efforts to gear up VS Code for Blazor start with initial support for Razor, its ASP.NET programming syntax for creating dynamic Web pages with C# or VB.NET. That markup syntax for embedding server-based code into Web pages consists of Razor markup, C# and HTML.

The company recently announced that Razor support in VS Code was available in preview, baked in to the C# for Visual Studio Code extension available in the Visual Studio Code Marketplace.

The initial support introduces functionality currently limited to offering code-completion options for HTML, C# and Razor directives in ASP.NET Core projects, along with the "red squiggles" that provide diagnostic information such as a possible problem.

Microsoft's Daniel Roth emphasized that this first alpha release for Razor tooling in VS Code comes with a number of limitations and known issues, including the lack of support for ASP.NET projects or Blazor projects.

"Even though the functionality of Razor tooling is currently pretty limited, we are shipping this preview now so that we can start collecting feedback," Roth said. Fleshing out the Razor support is a prerequisite for eventually adding Blazor support in VS Code, Roth indicated.

Ironically, the VS Code preview support for Razor -- and eventually Blazor -- was introduced shortly after client-side Blazor problems were reported by Microsoft, perhaps tempering that aforementioned Blazor buzz somewhat. Specifically, Microsoft revealed that its Blazor effort is being hampered by problems in working with WebAssembly, itself a young, experimental technology that provides the foundation of the Blazor effort with its goal of providing an assembly-like language that acts as a compilation target to enable C, C++, C# and other code to run in the browser.

Those problems prompted Microsoft to delay the client-side Blazor effort that depends so heavily upon WebAssembly, though the server side is progressing faster (under the moniker "Razor Components"), to the point where server-size Blazor is planned to be included in next year's release of .NET Core 3.0.

Meanwhile, work on Razor/Blazor support in VS Code will continue. "Next up we are working on tag helper support," Roth said of the Razor preview effort. "This will include support for tag helper completions and IntelliSense. Once we have tag helper tooling support in place we can then start work on enabling Blazor tooling support as well. Follow our progress and join in the conversation on the https://github.com/aspnet/Razor.VSCode repo."

About the Author

David Ramel is an editor and writer at Converge 360.

comments powered by Disqus

Featured

  • IDE Irony: Coding Errors Cause 'Critical' Vulnerability in Visual Studio

    In a larger-than-normal Patch Tuesday, Microsoft warned of a "critical" vulnerability in Visual Studio that should be fixed immediately if automatic patching isn't enabled, ironically caused by coding errors.

  • Building Blazor Applications

    A trio of Blazor experts will conduct a full-day workshop for devs to learn everything about the tech a a March developer conference in Las Vegas keynoted by Microsoft execs and featuring many Microsoft devs.

  • Gradient Boosting Regression Using C#

    Dr. James McCaffrey from Microsoft Research presents a complete end-to-end demonstration of the gradient boosting regression technique, where the goal is to predict a single numeric value. Compared to existing library implementations of gradient boosting regression, a from-scratch implementation allows much easier customization and integration with other .NET systems.

  • Microsoft Execs to Tackle AI and Cloud in Dev Conference Keynotes

    AI unsurprisingly is all over keynotes that Microsoft execs will helm to kick off the Visual Studio Live! developer conference in Las Vegas, March 10-14, which the company described as "a must-attend event."

  • Copilot Agentic AI Dev Environment Opens Up to All

    Microsoft removed waitlist restrictions for some of its most advanced GenAI tech, Copilot Workspace, recently made available as a technical preview.

Subscribe on YouTube