kevinrue / OBDS_slides

Slides for the OBDS course.
3 stars 0 forks source link

Error when rendering html to pdf using renderthis::to_pdf() #316

Open liezeltamon opened 2 weeks ago

liezeltamon commented 2 weeks ago

renderthis::to_pdf("index.cluster.html", "index.cluster.pdf") ✖ Rendering index.cluster.html into index.cluster.pdf ... failed Error in force(expr) : Failed to generate output. Reason: Failed to open http://127.0.0.1:7116/favicon.ico (HTTP status code: 404)

Refer to https://github.com/jhelvy/renderthis/issues/77

Temporary fix is to add this in the <head> section of html file: <link rel="shortcut icon" href="#" />

liezeltamon commented 1 week ago

@kevinrue

pagedown could be an alternative to renderthis but it still needs that temporary fix above because the function works the same way as renderthis::to_pdf()

pagedown::chrome_print("index.cluster.html", "index.cluster.pdf")
kevinrue commented 1 week ago

Oh cool. I've used pagedown before but not in a while