Skip to content

Instantly share code, notes, and snippets.

@enappd
Created July 31, 2021 16:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save enappd/5e4dd5b6d76e378724ec0bdaceddb61b to your computer and use it in GitHub Desktop.
Save enappd/5e4dd5b6d76e378724ec0bdaceddb61b to your computer and use it in GitHub Desktop.
Ionic http calls demo - Ionic Native Advanced
import { NgModule } from '@angular/core';
import { HttpBackend, HttpXhrBackend } from '@angular/common/http';
import { NativeHttpModule, NativeHttpBackend, NativeHttpFallback } from 'ionic-native-http-connection-backend';
import { Platform } from '@ionic/angular';
@NgModule({
declarations: [],
imports: [
NativeHttpModule
],
bootstrap: [],
entryComponents: [],
providers: [
{provide: HttpBackend, useClass: NativeHttpFallback, deps: [Platform, NativeHttpBackend, HttpXhrBackend]},
],
})
export class AppModule {
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment