RE: How to reference the native highcharts library from NetSuite
We are looking at creating some custom charts within a Portlet. I know that NetSuite natively uses Highcharts for their display. Does anyone know the fqdn to include the highcharts javascript library for use with SuiteScript?
My recommendation would be to download highcharts yourself and upload a copy to the File Cabinet. You can then reference it like any other module from the File Cabinet. You may need to shim it if highcharts is not distributed as an AMD module. This puts you in control of what version is in use and where it lives, and protects you from NetSuite abandoning highcharts.
The issue with using HighCharts directly is their licensing. As far as I can tell, this would fall under an OEM license (since we’re not the ones hosting it), and that’s more than I want to pay just to have charts show up in the same style as the NetSuite native ones when we need charting outside the bounds of what’s possible within NetSuite.
TinMonkey009
Highcharts is loaded as a property of window, but your portlet loads in an iFrame so you have to hit the parent scope to get access to highchairs… e.g.:
window.parent.Highcharts