Get this \"No provider for ConnectionBackend!\" error when trying to use http
with a promise.
// ... tl;dr import a bunch of
Import the HttpModule in your module instead of registering Http
as a provider.
import {HttpModule} from '@angular/http';
@NgModule({
imports: [HttpModule],
declarations: [
PostComponent
],
providers: [
Actions,
MyService
],
bootstrap: [MyComponent]
})
The HttpModule registers providers for all its services.