• 개요
@angular/common/http

withXhr

함수
안정화

Configures the current HttpClient instance to make requests using the Xhr API.

API

설명

Configures the current HttpClient instance to make requests using the Xhr API.

Use this feature if you want to report progress on uploads as the Xhr API supports it.

Do not use withXhr in server-side rendering (SSR) environments. XHR support on the server is deprecated and is intended to be removed in Angular 23 because the underlying xhr2 library does not safely handle redirects (e.g. it can forward Authorization headers on cross-origin redirects and is susceptible to denial-of-service via redirect loops).

상세 내용으로 이동