clarketm / TableExport

The simple, easy-to-implement library to export HTML tables to xlsx, xls, csv, and txt files.
https://tableexport.travismclarke.com/
Apache License 2.0
888 stars 289 forks source link

$.fn.tableExport.ignoreCSS Doesn't Work - TableExport.prototype.ignoreCSS does - using jQuery #143

Closed own3mall closed 6 years ago

own3mall commented 6 years ago

I'm using the latest version of TableExport v5 with jQuery 3.x, and when I use the below line, it doesn't work.

$.fn.tableExport.ignoreCSS = [".tableexport-empty", ".other-empty-class"];

However, this worked:

TableExport.prototype.ignoreCSS = [".tableexport-empty", ".other-empty-class"];

I would assume they should both work. I called them right before I initialized a table export instance using:

$('.myTable').tableExport();
clarketm commented 6 years ago

@own3mall – You are correct, thank you for identifying this. I have a fix in the latest release v5.0.3.