Answer the question
In order to leave comments, you need to log in
Error during WebSocket handshake: Unexpected response code 400. How to overcome?
In general, there is Web API and Angular face.
On the Web API side, I wrote:
services.AddCors(options =>
{
options.AddPolicy("CorsPolicy", b =>
{
b.AllowAnyOrigin()
.AllowAnyMethod()
.AllowAnyHeader()
.AllowCredentials();
}
);
});
app.UseCors("CorsPolicy");
this._httpClient.get(`Адрес API`);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question