jqPlot resize bar charts

To make a jqPlot bar chart resizeable, you need to do this:
$(window).on('resize', function () {
$.each(chart.series, function(index, series) {
series.barWidth = undefined;

where "chart" is the object returned by $.plot when initializing the plot.


Popular posts from this blog

Compare integer variable in django templates

Top things to do after installing Manjaro KDE

PIP - upgrade all packages from requirements.txt (interactively)