Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to stop xaringan's keyboard shortcuts while searching in a DT::datatable()?

xaringan's keyboard shortcuts interfere with DT::datatable() search functionality. It can even be seen in xaringan's example presentation (for instance, attempt to search for "m").

How can I stop this from happening? It is practically impossible to search for anything in a DT::datatable().

like image 413
arcruz0 Avatar asked Oct 29 '25 08:10

arcruz0


1 Answers

You can disable the keyboard shortcut by using frameWidget in widgetframe R package. Below is a working example.

```{r}
library(widgetframe)
library(DT)
dt <-  datatable(iris)
frameWidget(dt)
```
like image 133
Emi Avatar answered Oct 31 '25 01:10

Emi



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!