RangeError:IONIC 2和Angular 2超出最大调用堆栈大小

时间:2017-02-08 15:46:16

标签: jquery angular ionic2

我的组件代码是,我在这里调用第三部分jquery库:

import { Component } from '@angular/core'; 
import { Http } from '@angular/http'; 
declare var jQuery:any; 
import '../../assets/js/d3.v3.js'; 
declare var d3: any; 
import '../../assets/js/zackscharts.js'; 
declare var PriceChart: any;


    @Component({   selector: 'page-zacks-chart',  templateUrl: 'zacks-chart.html' })

export class ZacksChartPage {

    title : string;
    description : string;
    ticker : string;
    upperName : string;
    chartData = {};

constructor()
  {
    this.title = 'Zacks Chart';
    this.description = 'Zacks Chart Table';    
  }

ngOnInit()
 {  
     this.init_charts( 'chart_form', 'chart_canvas' );     
 }

init_charts( form_id, chart_id )
{
// call an API to fetch data
}
}

但是当我在浏览器上运行此应用程序时返回错误

RangeError: Maximum call stack size exceeded
    at Dataset.PriceChart.Dataset.Dataset.find (http://localhost:8100/build/main.js:109239:23)
    at Dataset.PriceChart.Dataset.Dataset.fetch (http://localhost:8100/build/main.js:109211:26)
    at PriceChart.parseData (http://localhost:8100/build/main.js:107846:30)
    at PriceChart.run (http://localhost:8100/build/main.js:107948:34)
    at Dataset.PriceChart.Dataset.Dataset.fetch (http://localhost:8100/build/main.js:109212:24)
    at PriceChart.update (http://localhost:8100/build/main.js:107920:33)
    at http://localhost:8100/build/main.js:107848:34
    at Dataset.PriceChart.Dataset.Dataset.fetch (http://localhost:8100/build/main.js:109212:24)
    at PriceChart.parseData (http://localhost:8100/build/main.js:107846:30)
    at PriceChart.run (http://localhost:8100/build/main.js:107948:34)

我对Angular 2很新。我没有使用任何缩小的库。任何帮助将不胜感激。

0 个答案:

没有答案