rstudio / DT

R Interface to the jQuery Plug-in DataTables
https://rstudio.github.io/DT/
Other
596 stars 182 forks source link

Please consider updating the embedded version of noUiSlider #1023

Open michaelquinn32 opened 1 year ago

michaelquinn32 commented 1 year ago

Hi everyone!

The current version of noUiSlider is 15.6.1 https://github.com/leongersen/noUiSlider/releases/tag/15.6.1

The version within DT is 7.0.10, which according to a comment is from 2015-03-17.

Unfortunately, we've found that these versions aren't compatible and sliders won't render if using the most recent version. Here's an example error from within Chrome.

image

Would it be possible to update DT?

Thanks!


By filing an issue to this repo, I promise that

I understand that my issue may be closed if I don't fulfill my promises.

yihui commented 1 year ago

Could you provide a reproducible example? I don't see the problem with DT::datatable(iris, filter = 'top').

michaelquinn32 commented 1 year ago

Thanks for taking a look.

To reproduce the error, you need to build the package with the js files for noUiSlider replaced for the most recent version.

You can then call DT::datatable(iris, filter = 'top') to generate the error I showed above.

Some context: We are trying to keep our js libraries up to date, and we build all libraries (including R package with embedded JS) from the same source. This is how we noticed the change in noUiSlider.

Let me know how else I can help!

yihui commented 1 year ago

I see what you mean now. I was aware of the fact that later versions of noUiSlider doesn't work with DT. I tried it a few years back, and felt it was too complicated to upgrade at that time because of major changes in noUiSlider's API. Since the work is not trivial, I don't have much time for this package anymore (I've been hoping to get it off my shoulders for a long time but nobody wants to take it), and the old version works fine, I'm not highly motivated to upgrade. If I have to do it, the most convincing reason would be security issues. Otherwise I'd welcome contributions via pull requests. Thanks!

michaelquinn32 commented 1 year ago

Thanks for letting me know! If you don't mind, I'd like to leave this open. In the meantime, I'll ask around a bit. Maybe someone else can help here.