Demonstration of using Highcharts for graph rendering in native iOS app
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
ChartExample.xcodeproj
ChartExample
ChartExampleTests
HighCharts
.gitignore
LICENSE
README.md

README.md

Overview

Demonstration of using Highcharts for graph rendering in native iOS app. The app is written in Swift 3.0.2 (requires Xcode 8.2+). Highcharts is a JS based charting engine and the sample app demonstrates the ability to render charts using Highcharts within a WKWebview in a native app. The sample app also demonstrates drill down capabilities.

Details

The sample app demonstrates the following :-

  • Ability to dynamically load chart data / chart options
  • Ability to listen to element selection events
  • Multi-level Drilling down / Drilling up

The app uses a WKWebView to load the Highchart and uses WebKit messaging interface for communication between the native iOS app world and JS world.

The native iOS layer sends the chart data / options to the JS charting layer using the evaluatejavascipt method.

The native iOS layer listens to drillup/drill down events from the chart using the WKScriptMessageHandler interface and can redraw the chart with appropriate chart data.

Refer to http://www.priyaontech.com/2017/01/highcharts-support-in-a-native-ios-app/ for a simple example that demonstrates loading of Highcharts chart with static chart data.

#License MIT License. See LICENSE for details.