itables buttons in html outputs #8633
Replies: 4 comments 7 replies
-
Could you edit the title of the thread to state what this is about? Could you share a small self-contained "working" (reproducible) example to work with of what you want as input, i.e., a complete Quarto document or a Git repository? Thanks. You can share a self-contained "working" (reproducible) Quarto document using the following syntax, i.e., using more backticks than you have in your document (usually four ````qmd
---
title: "Reproducible Quarto Document"
format: html
engine: knitr
---
This is a reproducible Quarto document using `format: html`.
It is written in Markdown and contains embedded R code.
When you run the code, it will produce a plot.
```{r}
plot(cars)
```

The end.
```` Additionally and if not already given, please share the output of |
Beta Was this translation helpful? Give feedback.
-
Hello, sure - I hope the examples below help: In this dashboard example, itables buttons are displayed: ---
title: "Dashboard output"
format: dashboard
---
```{python}
import seaborn as sns
from itables import show
penguins = sns.load_dataset("penguins")
show(penguins, buttons = ['copy', 'excel', 'pdf'])
``` However, in a similar html example, buttons are not displayed. Is it possible to enable them, please? ---
title: "HTML output"
format: html
---
```{python}
import seaborn as sns
from itables import show
penguins = sns.load_dataset("penguins")
show(penguins, buttons = ['copy', 'excel', 'pdf'])
``` quarto check output: Quarto 1.4.549
[>] Checking versions of quarto binary dependencies...
Pandoc version 3.1.11: OK
Dart Sass version 1.69.5: OK
Deno version 1.37.2: OK
[>] Checking versions of quarto dependencies......OK
[>] Checking Quarto installation......OK
Version: 1.4.549
Path: C:\Program Files\Quarto\bin
CodePage: 1252
[>] Checking tools....................OK
TinyTeX: (external install)
Chromium: 869685
[>] Checking LaTeX....................OK
Using: TinyTex
Path: C:\Users\[username]\AppData\Roaming\TinyTeX\bin\win32\
Version: undefined
[>] Checking basic markdown render....OK
[>] Checking Python 3 installation....OK
Version: 3.11.5
Path: C:/Users/[username]/AppData/Local/Programs/Python/Python311/python.exe
Jupyter: 5.2.0
Kernels: python3
[>] Checking Jupyter engine render....OK
[>] Checking R installation...........OK
Version: 4.3.1
Path: C:/Users/[username]/AppData/Local/Programs/R/R-4.3.1
LibPaths:
- C:/Users/[username]/AppData/Local/Programs/R/R-4.3.1/library
knitr: 1.45
rmarkdown: 2.25
[>] Checking Knitr engine render......OK |
Beta Was this translation helpful? Give feedback.
-
Hello, I am having a similar issue. Is there any way to make Datatables extensions work in Quarto html files? https://mwouts.github.io/itables/extensions.html In my case, I need the searchBuilder instead of buttons but neither of them work in Quarto and both of them work in Jupyter. |
Beta Was this translation helpful? Give feedback.
-
@RichardGillott I think I know what the original problem was. Back in February only ITables==1.7 was available, and that version did not support the DataTables extensions. I do remember that although the extensions were not provided by ITables, by some magic (well I mean something outside of ITables) they were still available in some Quarto contexts. Since ITables==2.0 (March 2024, cf. https://mwouts.github.io/itables/changelog.html) the extensions are bundled with ITables and now they are indeed expected to work in all the HTML rendering contexts. Would you mind confirming that they work for you too now? |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
itables buttons in html outputs
Hello, with Quarto 1.4 dashboards, we can now enable itables buttons as shown in the documentation.
The documentation states "All base options are available, as well as the options for the following extensions (which are automatically included by Quarto)" - but this only seems to be the case for dashboard outputs. Is there a way to enable this behaviour for html outputs, please?
Beta Was this translation helpful? Give feedback.
All reactions