feature request:
allow for jquery-style 'method chaining' for those flot (& flot plugin) methods
that return 'void', i.e. those methods that dont return a value (such as the
'getData()' method);
accomplish this goal by adding 'return this;' to end of each utility function.
this will return the plot object and allow for method chaining (which is a
standard jquery construct).
example:
var plt=$.plot(obj,data,opts);
plt.highlight(hiPt).setCrosshair(chOpts).doSomePluginMethod(pOpts).doSomeOtherMe
thod(xOpts).doSomethingElse(yOpts);
this change would need to be applied to each existing 'void' method in both the
base flot library & in each flot plugin. plugin developers would consequently
be expected to follow the same coding guideline of returning the plot object
from all general purpose 'void-returning' utility functions.
Original issue reported on code.google.com by changos...@gmail.com on 14 Aug 2012 at 6:39
Original issue reported on code.google.com by
changos...@gmail.com
on 14 Aug 2012 at 6:39