Suppose we need to dynamically construct plugin calls such as
$('#myDiv').myPlugin({a:'a',b:'b'});
will be something like:
function funcCallBuilder(selector, func, opts){
//dynamically construct plugin call here
}
using:
funcCallBuilder('#myDiv', 'myPlugin', {a:'a',b:'b'});
Can someone point out the correct way of doing this?