I am getting the following warning from after upgrading an my ASP.NET Core Angular application from ASP.NET Core 3.0 Preview 3 to ASP.NET Core 3.0 Preview 4.
1>Startup.cs(75,13,80,15): warning MVC1005: Using 'UseMvc' to configure MVC is not supported while using Endpoint Routing. To continue using 'UseMvc', please set 'MvcOptions.EnableEndpointRounting = false' inside 'ConfigureServices'.
Then if I set MvcOptions.EnableEndpointRounting = false as follows:
services.AddMvc(option => option.EnableEndpointRouting = false)
.AddNewtonsoftJson();
Then the warning goes away. My question is if I want to use EndpointRounting then should I remove the following code:
app.UseMvc(routes =>
{
routes.MapRoute(
name: "default",
template: "{controller}/{action=Index}/{id?}");
});
if not then what change I have to make?