I'm trying to declare a click handler using an array of strings which contains the selectors and corresponding methods to call:
['start','clear','stop','plus','minus'].forEach(function(el) {
$("#" + el).click(function() {
Timer.el();
});
});
The point is to change Timer."array[index]"();. I tried el but the console shows an error.