I am getting "Access to XMLHttpRequest at 'http://localhost:60261/api/student/?Name=qwwertyqwe&Age=21' from origin 'http://localhost:4200' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource."
Although the API is called and it is working as expected, but there is Error thrown at Chrome console. Things I have done.
I have install CORS nuget package in the API.
I tried to add EnableCorsAttribute and config.EnableCors in WebAPIConfig.cs file but it is also showing error.
Below is the Chrome screenshot: