score:1

You can use eval(). Note that this is a security hole.

The problem is that you are passing a function via JSON. JSON does not support this.

Btw, jquery.parseJSON() is deprecated, use JSON.parse()

Here's an example:

data = JSON.parse(x);
data.yAxis.labels.formatter = eval(data.yAxis.labels.formatter);

Related Query

More Query from same tag