I used angular .net core 2.2 template to build application.In localhost working fine,When i host to IIS Im getting this error.Im using IIS 10 to host the application.
<
By removing V2 from modules="AspNetCoreModuleV2" worked for me. Note that my issue was related to running a .net core web api from visual studio. IE Express failed with a code 500 and upon investigating the error log describing "Handler 'aspNetCore' has a bad module.." was resolved by replacing with the below.