Error: No provider for HttpHandler in angular2

HttpClient is introduced in angular 4.3,so if you want to use HttpClient you need to import HttpClientModule from '@angular/common/http'. Make sure to import HttpClientModule after BrowserModule as shown below. This official doc and so answer will give you indepth information.

import { HttpClientModule } from '@angular/common/http';

@NgModule({
 imports: [
   BrowserModule,
   HttpClientModule
 ],
 ...

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)