im getting alot of this error in my app but translate is working
my app.module.ts
import { HomePage } from '../pages/home/home';
import { SignupPage } from '../pages/signup/signup';
import { ClinicFilterPage } from './../pages/clinic-filter/clinic-filter';
import { HosFilterPage } from './../pages/hos-filter/hos-filter';
import { ScanFilterPage } from './../pages/scan-filter/scan-filter';
import { ForgotpassePage } from './../pages/forgotpasse/forgotpasse';
import { AppSettingsPage } from './../pages/app-settings/app-settings';
import { ProfilePage } from './../pages/profile/profile';
import { ContactPage } from './../pages/contact/contact';
import { FavoritesPage } from './../pages/favorites/favorites';
import { SpecProfilePage } from './../pages/spec-profile/spec-profile';
import { TopicListPage } from './../pages/topic-list/topic-list';
import { HospitalsPage } from './../pages/hospitals/hospitals';
import { ScansPage } from './../pages/scans/scans';
import { ClinicProfilePage } from '../pages/clinic-profile/clinic-profile';
import { SpecViewPage } from './../pages/spec-view/spec-view';
import { ClincPage } from './../pages/clinc/clinc';
import { AppHomePage } from './../pages/app-home/app-home';
import { ConfirmMailPage } from '../pages/confirm-mail/confirm-mail';
import { HospitalProfilePage } from '../pages/hospital-profile/hospital-profile';
import { ScanProfilePage } from '../pages/scan-profile/scan-profile';
import { HttpModule } from '@angular/http';
import { BrowserModule } from '@angular/platform-browser';
import { ErrorHandler, NgModule } from '@angular/core';
import { IonicApp, IonicErrorHandler, IonicModule } from 'ionic-angular';
import { SplashScreen } from '@ionic-native/splash-screen';
import { StatusBar } from '@ionic-native/status-bar';
import { HttpClientModule, HttpClient } from '@angular/common/http';
import { MyApp } from './app.component';
import { RestProvider } from '../providers/rest/rest';
import { AuthServiceProvider } from '../providers/auth-service/auth-service';
// import { OneSignal } from '@ionic-native/onesignal';
import { Geolocation } from '@ionic-native/Geolocation';
import { Device } from '@ionic-native/Device';
import { Facebook } from '@ionic-native/facebook';
import { IonicStorageModule } from '@ionic/storage';
import { NativeGeocoder } from '@ionic-native/native-geocoder';
import { Keyboard } from '@ionic-native/keyboard';
import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
import { TranslateHttpLoader } from '@ngx-translate/http-loader';
import { CallNumber } from '@ionic-native/call-number';
import { GoogleMaps } from '@ionic-native/google-maps';
import { LaunchNavigator } from '@ionic-native/launch-navigator';
import { SettingsServiceProvider } from '../providers/settings-service/settings-service';
export function createTranslateLoader(Http: HttpClient) {
return new TranslateHttpLoader(Http, './assets/i18n/','.json')
}
@NgModule({
declarations: [
MyApp,
HomePage,
SignupPage,
AppHomePage,
ConfirmMailPage,
ClincPage,
SpecViewPage,
ScansPage,
HospitalsPage,
TopicListPage,
SpecProfilePage,
AppSettingsPage,
FavoritesPage,
ContactPage,
ProfilePage,
ForgotpassePage,
ScanFilterPage,
HosFilterPage,
ClinicFilterPage,
ClinicProfilePage,
HospitalProfilePage,
ScanProfilePage
],
imports: [
BrowserModule,
HttpClientModule,
HttpModule,
IonicModule.forRoot(MyApp),
IonicStorageModule.forRoot(),
TranslateModule.forRoot({
loader: {
provide: TranslateLoader,
useFactory: createTranslateLoader,
deps: [HttpClient]
}
}),
// TranslateModule.forChild()
],
bootstrap: [IonicApp],
entryComponents: [
MyApp,
HomePage,
SignupPage,
AppHomePage,
ConfirmMailPage,
ClincPage,
SpecViewPage,
ScansPage,
HospitalsPage,
TopicListPage,
SpecProfilePage,
AppSettingsPage,
FavoritesPage,
ContactPage,
ProfilePage,
ForgotpassePage,
ScanFilterPage,
HosFilterPage,
ClinicFilterPage,
HospitalProfilePage,
ClinicProfilePage,
ScanProfilePage,
HospitalProfilePage
],
providers: [
StatusBar,
SplashScreen,
{provide: ErrorHandler, useClass: IonicErrorHandler},
RestProvider,
AuthServiceProvider,
Facebook,
Geolocation,
Device,
// OneSignal,
Keyboard,
NativeGeocoder,
CallNumber,
GoogleMaps,
LaunchNavigator,
SettingsServiceProvider
]
})
export class AppModule {
}