Aspnetcore: Visual Basic .NET (VB.NET) support in ASP.NET Core

Created on 14 Feb 2019  路  8Comments  路  Source: dotnet/aspnetcore

we need a lower barrier for ASP.NET core which I see with VB.NET support
Goal is to get more semi pro and Website devs (not Project) to use that platform

I open that cause the thread owner of
https://github.com/aspnet/AspNetCore/issues/2738
closed it by Frustration.

area-blazor

Most helpful comment

Hi folks, while there are many interesting ideas being discussed, there are still no plans for adding direct support for this.

Today you can use VB.NET for writing many parts of ASP.NET Core applications, such as startup code, MVC/API controllers, SignalR hubs, authentication logic, models, etc. But there is no support for VBHTML and at this time there are no plans to change that.

All 8 comments

I agree with the saying that vbhtml is a lost cause, because VB.NET code doesn't fit well amoung HTML, CSS and JavaScript syntax! Instead, I ask for vbxaml !
I posted this suggestion in VB.NET repo months ago:
https://github.com/dotnet/vblang/issues/329
These are quotes:

Let VB.NET ride the new WebAssembly wave:
After WebAssembly and Blazor, the opportunity represents itself: It is logical now to write XAML instead of HTML5 (differences are minimal) and write VB.NET instead of Java script (the same way C# replaces Java now in Blazor).
There is already a project named Ooui trying to do that in C#.
I think, VB.NET should do the same, and have a project to design ASP.NET pages with XAML and VB.NET code, making use of the work done in SilverLight, Blazor and Ooui. If this starts now, it can grow steadily, instead waiting for Blazor and Ooui to stable and then MS say:
Sorry, it will be expensive for VB.NET to catch up!

VBlazor (.vbxaml) will make desktop developers experienced in VB.NET and WPF/UWP move to ASP.NET smoothly.
VBLazor would be similar to uwp/wpf design view, but with two code-behind files, one for server vb.net codes, and another for client (script) codes, with the ability to use MVVM pattern to organize large projects. XAML will be complied to html5, Xaml styles will be compiled to CSS, and VB.NET script codes will be compiled to WebAssembly.

Hi folks, while there are many interesting ideas being discussed, there are still no plans for adding direct support for this.

Today you can use VB.NET for writing many parts of ASP.NET Core applications, such as startup code, MVC/API controllers, SignalR hubs, authentication logic, models, etc. But there is no support for VBHTML and at this time there are no plans to change that.

cc @DamianEdwards

@Eilon
I created a VB.NET ASP.NET MVC (.net Core 3.0 preview) Project based on a C# project, and of cource still using cshtml pages. But when I run it, I got the error: can't find Index.cshtml, while it exists in the Views\Home folder! This works for .NET Core 2.1 but seems to have a problem with .NET Core 3.0 preview! What is wrong?

@VBAndCs can you please log a new bug for this specific issue, including how to reproduce it?

@Eilon

8783

@hannespreishuber
I am building a Vazor (VB Razor) using XML literals supported in VB.NET code. More details in here: https://github.com/dotnet/vblang/issues/397
I have proven the concept, but I need help to creata full View Engine for Vazor, as I showed there. I am crying out for VB.NET fans :)
Thanks.

.NET Core does support VB such that you can create and build VB based projects. VB based class libraries can of course be used from ASP.NET Core and Blazor apps as they compile to .NET IL just like any other .NET language. Razor, however, is based on C# in .NET Core. Razor is used for authoring MVC views, Razor pages, and Blazor components. The Razor SDK compiles Razor files into C# class class. This means that Razor files need to live in a C# project to get an appropriate tooling experience. Maintaining support for Razor for just C# is already a significant expense as it involves being able to parse a mixture of C# code and markup. We have no plans to add Razor support for other languages because of the added cost involved.

Was this page helpful?
0 / 5 - 0 ratings