-
Notifications
You must be signed in to change notification settings - Fork 385
Open
Labels
bugSomething isn't workingSomething isn't workingjupytermathany issue related to math support in specific formatsany issue related to math support in specific formatsplotlyrevealjsIssues with the revealjs formatIssues with the revealjs format
Description
---
format: revealjs
keep-ipynb: true
---
## Math
$$
1 + 1
$$
$1+1$
## Plotly script
```{python}
#| echo: false
#| output: true
import plotly.graph_objects as go
import numpy as np
C = 0
x_range = np.linspace(-10, 10, 100)
y_initial = np.full_like(x_range, C)
fig = go.Figure()
fig.add_trace(
go.Scatter(
x=x_range,
y=y_initial,
mode='lines',
name=f'Y = {C:.2f}',
line=dict(width=3)
)
)
fig
```This works ok it seems, but Plotly usage will add a second time the Mathjax library. Related to
when using embed-ressources: true this creates problem as math won't show in first slide
without the plotly part, it shows ok (with default self-contained-math: false, or opt-in to true)
What happens is that plotly insertion of mathjax is conflicting. And it seems this is added always, even when math not used.
Probably related to include_mathjax option being activated somehow in our jupyter context execution . Some renderer have it to false: https://github.com/plotly/plotly.py/tree/main/plotly/io
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingjupytermathany issue related to math support in specific formatsany issue related to math support in specific formatsplotlyrevealjsIssues with the revealjs formatIssues with the revealjs format