2

I want to convert my Plotly Dash web app to a pdf that is downloadable when a user clicks a button.

I'm searching for a .toString() type of function that will act on something like html.Div() to give me the string <div>...</div>.

This is so I can use the python package fpdf to write the web page to a pdf such as shown here.

I've had a look around the Dash documentation but can't find what I'm looking for, hoping I don't have to dive into the render pipeline.

  • I'm not sure there is a way to do this for a given component, though you can export the whole figure html : `fig.write_html("path/to/file.html")`. – EricLavault Dec 08 '21 at 13:39

0 Answers0