mvdkwast / obsidian-copy-as-html

Obsidian plugin: copy document as HTML, including images
MIT License
42 stars 11 forks source link

[Question] Resize images as render in obsidian #33

Closed xh542428798 closed 11 months ago

xh542428798 commented 1 year ago

Hello author, when I preview my notes in Obsidian, they are always fixed to the same size. However, when I export them to HTML, they are in their original size, which results in inconsistent image sizes. How can I set it so that the exported images are all the same size?

In obsidian: image

After export in html: image

mvdkwast commented 11 months ago

Hello reporter ! I think you should be able to fix your image sizes using a custom stylesheet.

I didn't test, but something like :

img {
  width: 400px;
}

How the images are rendered may depend on where you paste the document unfortunately.