[ Web Proxy ]
URL:
Viewing: https://angular.dev/api/common/http/HttpClientModule [Back]  [Original]

HttpClientModule Angular Skip to main content
menu
close
more_horiz
menuAPI
@angular/common/http

HttpClientModule

NgModule
deprecated

Configures the dependency injector for HttpClient with supporting services for XSRF. Automatically imported by HttpClientModule.

Deprecation warning

use provideHttpClient(withInterceptorsFromDi()) as providers instead

orthos-back.svg [orthos-back.svg]

On this page

    arrow_upward_alt Back to the top

    API

        
          class HttpClientModule {}
        
        

    Description

    Configures the dependency injector for HttpClient with supporting services for XSRF. Automatically imported by HttpClientModule.

    You can add interceptors to the chain behind HttpClient by binding them to the multiprovider for built-in DI token HTTP_INTERCEPTORS.

    When importing the HttpClientModule, the HttpBackend is set to using the HttpXhrBackend. If you want to use the FetchBackend, use provideHttpClient instead.

    Jump to details

    Web Proxy Viewer  |  New URL  |  Original Page