Did you find the method to fix it? I have the same question of Visual Studio Code for C#.
Visual Studio Code syntax errors not being highlighted for C#
I am creating a new console project in Visual Studio Code using "dotnet run new console -n 'name'", but syntax errors are not being highlighted anymore. Even when I forget to use a ";" or make a syntax error, I don't see error squiggles. This only happens in C#. I have installed and updated all necessary extensions, and even tried reinstalling .NET, Visual Studio Code, and C# Dev Kit, changing error squiggle settings, and going back to a previous version of .NET. Before, reinstalling .NET or C# Dev Kit solved the issue, but that is not the case anymore. I use Windows 11 and have the Error Lens extension installed. Any suggestions?