I know it's not part of the JSON data format specification, but is there a way to pass JavaScript functions within JSON created by Julia?
So much of what I do in Julia involves generating JSON, and in some JavaScript libraries, the parser will evaluate functions (and seems that it is the JS library dev preference).
So is there a way to create something like:
{
symbolSize: function (data) {
return Math.sqrt(data[2]) / 5e2;
}
}
I know it's not part of the JSON data format specification, but is there a way to pass JavaScript functions within JSON created by Julia?
So much of what I do in Julia involves generating JSON, and in some JavaScript libraries, the parser will evaluate functions (and seems that it is the JS library dev preference).
So is there a way to create something like: