Repository is moved to https://github.com/troyanskiy/ngx-resource
It's implementation of ResourceHandler
which uses Angular HttpClient
& npm i --save @ngx-resource/core @ngx-resource/handler-ngx-http
In you app module
// AoT requires an exported function for factories
export function myHandlerFactory(http: HttpClient) {
return new MyResourceHandler(http);
}
@NgModule({
imports: [
BrowserModule,
BrowserAnimationsModule,
HttpClientModule,
// Default ResourceHandler uses class `ResourceHandlerHttpClient`
ResourceModule.forRoot()
// Or set you own handler
//ResourceModule.forRoot({
// handler: { provide: ResourceHandler, useFactory: (myHandlerFactory), deps: [HttpClient] }
//})
],
declarations: [...],
bootstrap: [...],
entryComponents: [...],
providers: [...]
})
export class AppModule {
}