You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When passing an array of objects to dataTable.columns() as suggested in the docs, _doColumnValueFormat throws an error that v.format is not a function. Instead of using this template for the columns:
chart.columns([
["Date", // Specify an Object = [Label, Fn]
function (d) { return d.date; }], ...
Either the docs should be changed (using a similar template to the one I pasted above), or the code should be changed:
_chart._doColumnValueFormat = function (v, d) {
return ((typeof v === 'function') ?
v(d) : // v as function
((typeof v === 'string') ?
d[v] : // v is field name string
// v.format(d) // v is Object, use fn (element 2)
//use element 2 instead:
v.[1](d) // v is Object, use fn (element 2)
)
);
};
to call so they match. If the code is changed, _doColumnHeaderFormat is also impacted by a similar issue.
The text was updated successfully, but these errors were encountered:
When passing an array of objects to dataTable.columns() as suggested in the docs, _doColumnValueFormat throws an error that v.format is not a function. Instead of using this template for the columns:
This one works instead:
Either the docs should be changed (using a similar template to the one I pasted above), or the code should be changed:
to call so they match. If the code is changed,
_doColumnHeaderFormat
is also impacted by a similar issue.The text was updated successfully, but these errors were encountered: