okay, i got it working.

first adding allowcodeexecution helped. but then once i started debugging the highcharts-export-server code in node, i found that there was an exception being thrown by phantomjs when evaluating (by way of injectjs) within highcharts-regression.js.

that module uses for (let i=.... turns out the let keyword is not supported by phantomjs. this was only used on one line in the whole module, so i created a local copy and edited it to for (var i=... and that fixed that problem.

now i'm getting my trend line.

but then i also have a "sma" series on the same chart. so i had to edit the node_modules/highcharts-export-server/build.js file and add stock/{{version}}/indicators/indicators.js as a cdnadditional entry. if you google how to add extra highcharts modules you will find details on how to do this -- on their forum. basically you edit build.js then run node build.js from the root of where you have the highcharts-export-server installed by npm (or where you cloned it).

note that the resources.files property wants a string of well formed json. it needs to be a comma separated list of filesystem paths or uris (that start with http). this property does not want an array of strings. just a singe string.

Related Query

More Query from same tag