Uncaught (in promise): Error: No provider for Http! Ionic 2.2.3

To resolve "No provider for Http!" Error in ionic to, add the HttpModule to your app.module.ts file.

import { HttpModule } from '@angular/http'; 
 
// Add "HttpModule" inside imports
  imports: [
    BrowserModule,
    HttpModule, // Add this
    IonicModule.forRoot(MyApp),
  ],

Screentshot - Error:

error1.PNG

 

 

Screenshot - Code Sample:

e2.PNG

Category: