vimalavinisha / angular2-google-chart

Angular 2 google chart
MIT License
59 stars 45 forks source link

How to integrate angular2-google-chart with angular-cli? #9

Open devrockzz opened 8 years ago

devrockzz commented 8 years ago

Please kindly guild me how i can integrate it with angular-cli as i am trying but its not working . So please give me the proper steps how i can integrate it with angular cli

manish153 commented 8 years ago

I would like to know this as well. It will be helpful for greater adoption.

RicardoVaranda commented 7 years ago

@devrockzz @manish153 I've made a tutorial here on how you guys can achieve this.

https://github.com/RicardoVaranda/Angular2-Google-Charts

All credits go to @vimalavinisha

BenDevelopment commented 7 years ago

Thank you for this tutorial. I figured out that your are loading that chart api each time in the diretive. It makes the chart display very slow. Maybe we can upgrade this script.

sup99 commented 7 years ago

Hi guys and thanks for the tutorial ! Yes. I noticed the poor performance and it was a no-go for me, but the chart supports 2 graphics that I needed so I had no choice to try to make it work better. I simply did this: 1) I just called this.drawGraph() on the chart component (i especially skipped loading the package) 2) On the index page, right after including the chart script, I only called once the following line google.charts.load('current', { 'packages': ['line'] });

I only needed to draw a couple of line charts, so I grabbed the minimum and it works blazing fast now. I hope this helps someone, cheers !

sudthenerd commented 6 years ago

@RicardoVaranda: Thanks a lot.

  1. thing i want to ask, that how to show location on hover of grey section.
ariklu commented 6 years ago

@sup99 could you please allaborate on step 1. in your answer. you call "this.drawGraph() on the chart component" ? -in angular component.ts file where is "loading the package" that you skip?

I really need this fix, but I just do not understand what to do

Thank you in advance