Closed
Description
When one invokes plotly.io.to_html(fig, include_plotlyjs=False, full_html=False)
the following
example output is produced:
'<div>\n \n \n <div id="8a9f01d7-9e37-401b-a602-15b3bbdac943"
class="plotly-graph-div" style="height:100%; width:100%;"></div>\n <script
type="text/javascript">\n \n window.PLOTLYENV=window.PLOTLYENV ||
{};\n \n if
(document.getElementById("8a9f01d7-9e37-401b-a602-15b3bbdac943")) {\n
Plotly.newPlot(\n \'8a9f01d7-9e37-401b-a602-15b3bbdac943\',\n
...
Note the \n
characters as well as a single quoted id
.
The resulting <div>
element appears like this when placed in a markdown document, i.e no plot
showing up:
Note I have ensured to include:
<script src="https://cdn.plot.ly/plotly-latest.min.js"></script>
above the <div>
element.
Removing the \n
characters and replacing the single quoted id
with double quotes seems to
resolve this issue.
See PR #2469
Metadata
Metadata
Assignees
Labels
No labels