angular / in-memory-web-api

The code for this project has moved to the angular/angular repo. This repo is now archived.
MIT License
1.18k stars 231 forks source link

WebHTTP AND InMemoryHTTP together #229

Open yandiro opened 5 years ago

yandiro commented 5 years ago

I would like to use in-memory but I need regular http requests to login to the system.

So I need only one module to use the in-memory-web-api. (How) can it be done?

vishal423 commented 5 years ago

you can intercept specific calls and let remaining flows through like below in your core module:

HttpClientInMemoryWebApiModule.forRoot(InMemoryDataService, {
  passThruUnknownUrl: true
})
yandiro commented 5 years ago

This solved the issue. Thank you very much !

you can intercept specific calls and let remaining flows through like below in your core module:

HttpClientInMemoryWebApiModule.forRoot(InMemoryDataService, { passThruUnknownUrl: true })