I want to display some data in form of charts in my ionic app. There are a lots of javascript chart libraries available. I am wondering which would be the best to use with ionic. Also will there be any issue with the mobile versions. Has anyone tried to use chart with ionic apps.
I experimented with Chart.js (http://www.chartjs.org/) , but this doesn’t seem to work well on mobile.
Can anyone suggest me options for charting which are compatible with ionic and also responsive and supported on mobile devices
I hate to replay with a “me too” but this is a great question! I think this should go in the official Learn Ionic section of the website when a solution is architected/implemented.
In the mean time, I’ve used jqplot in past non-ionic Cordova projects to some success. I’m not sure how well it will play with Ionic though since it depends on jquery.
I don’t know if Google Charts is the best option; however, I had prior experience with it so throwing it into this app was quick and easy with this angular module :
I’m using Flotr2 without any angular module and it works quite well.
I had only some issues putting the chart in a modal: when it showed up, the app closed anomaly. Can’t figure out why. Maybe css animations but I’m not sure.
Anyway, when choosing your library remember that SVG is supported from Android 3.0+ while Canvas from Android 2.1+.
PS: I used Google Charts before, but then switched to a standalone library because you can use google charts only if you have internet connection
All of them responsive and integarted with ionic very easily.
I didn’t get the chance to test them on various devices especially iOS devices. It would be great to have a report of the tests done on various devices.
Also feel free to fork the repo and add or modify it to include other libraries.
I used high chart. It working fine, Just change option chart type for various chart -
options: {
chart: {
type: ‘line’
}
},
I have checked bar and line till now.
I am having trouble when trying to run the application. It shows card with title. No Graph is shown. Also Can u please share anguler-chart.css file as I am not able to extract it from zip only js files were present in .zip.