我想添加谷歌图表并遵循此https://www.npmjs.com/package/angular2-google-chart
但是给我错误;未捕获的TypeError:(void 0)不是函数
直到今天我才能解决这个问题
我该如何解决这个问题? Thanx到现在
app.module.ts;
import { NgModule, ErrorHandler } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { IonicApp, IonicModule, IonicErrorHandler } from 'ionic-angular';
import { MyApp } from './app.component';
import { StatusBar } from '@ionic-native/status-bar';
import { SplashScreen } from '@ionic-native/splash-screen';
import { DbProvider } from '../providers/db/db';
import { IonicStorageModule } from '@ionic/storage';
import { HttpModule } from '@angular/http';
import { SQLitePorter } from '@ionic-native/sqlite-porter';
import { SQLite } from '@ionic-native/sqlite';
import { TaskServiceProvider } from '../providers/task-service/task-service'
import { ChartModule } from 'angular2-highcharts';
import * as highcharts from 'Highcharts';
import {GoogleChart} from 'angular2-google-chart/directives/angular2-google-chart.directive';
@NgModule({
declarations: [
MyApp,
KanalolusturPage,
KanalPage,
TabsPage,
GetlerPage,
PostlarPage,
UyelikPage,
ElementolusturPage,
VerilerPage,
GoogleChart
],
imports: [
BrowserModule,
HttpModule,
IonicModule.forRoot(MyApp),
IonicStorageModule.forRoot(),
ChartModule.forRoot(highcharts)
],
bootstrap: [IonicApp],
entryComponents: [
MyApp,
KanalolusturPage,
KanalPage,
TabsPage,
GetlerPage,
PostlarPage,
UyelikPage,
ElementolusturPage,
VerilerPage,
],
providers: [
StatusBar,
SplashScreen,
{provide: ErrorHandler, useClass: IonicErrorHandler},
DbProvider,
DbProvider,
SQLitePorter,
SQLite,
TaskServiceProvider
]
})
export class AppModule {}