AvaloniaUI/Avalonia

Visual Studio Avalonia UserControls problem in Views folder

Closed this issue · 2 comments

Describe the bug

the namespace created when creating a usercontrol using the template in Visual studio doesn't put the class in the right namespace in both the axamin andd the cs file
it puts the namespace as app.ViewName instead of App.Views.ViewName
viewlocator doesn't find the view because the namesoace is is wrong

To Reproduce

Right click on views folder and then add item and select avalonia usercontrol

Expected behavior

the name space should be correct
app.views.Classname

Avalonia version

11.3.6

OS

Windows

Additional context

Image Image

Viewlocator wont locate it unless the name space is correct
it did find it after I made this chage

Image I am new to c# programming and following a tutorial AngelSix made. I've been having fun until this stalled me for four hours Visual studio version September 25 version and the latest

Duplicate of AvaloniaUI/avalonia-dotnet-templates#235

Unfortunately, .NET templating SDK is not flexible enough to support autodetection of namespaces.