-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Description
Error in the startup project
I have errors, but still, I can compile and run the code without any issues.
To Reproduce
Steps to reproduce the behavior:
- Install ASP.NET core version, 3.1.0-preview1.19508.20
- Install the last update of Visual Studio, my version 16.4.0 Preview 2.0
- Create a new Blazor WebAssembly project with the latest Blazor project template in the empty solution
- Open the SurveyPrompt.razor page in the Shared folder of the new application
- You will see three types of errors
-
CS0111 Type 'SurveyPrompt' already defines a member called 'BuildRenderTree' with the same parameter types, Line 1
-
CS0102 The type 'SurveyPrompt' already contains a definition for 'Title' Line 15
-
CS0229 Ambiguity between 'SurveyPrompt.Title' and 'SurveyPrompt.Title'
Expected behavior
Open and see razor files without any issues and clear "Error List" tab of the Visual Studio
Screenshots
See the screenshot.

Here is the list of all nuget packages.

Additional context
If I open the compiled file in the background of the razor file and add a partial class keyword in the name of the class, errors will disappear.
This could be related to this feature, about partial class, https://devblogs.microsoft.com/aspnet/asp-net-core-updates-in-net-core-3-1-preview-1/
Thanks,
Ratomir