meteor-tabular icon indicating copy to clipboard operation
meteor-tabular copied to clipboard

Options as anonymous functions

Open illmat opened this issue 9 years ago • 2 comments

I just had a little discussion with an datatables author. https://github.com/DataTables/DataTables/pull/713

Basically, I want pass anonymous functions as options. For example:

language: {
  url: function () {
    return '/getDataTableLanguageFile/' + TAPi18n.getLanguage();
  }
}

or

title: function () {
  if (Meteor.isClient) {
    return TAPi18n.__('From');
  }
  return 'From';
}

It works like a charm with the PR I've submitted there.

They won't implement this at the moment. Would you mind if we implement this in your package?

illmat avatar Oct 29 '15 12:10 illmat

Several tickets could be solved with this. ( #147, #137, #115)

illmat avatar Oct 30 '15 07:10 illmat

+1

krawalli avatar Nov 02 '15 18:11 krawalli