Summary Images
Each post can have a cover image associated with it. This image is used in the summary view of the post.
You can also display it on the single post page by setting the showSummaryCoverInPost
parameter to true.
---
cover: /img/build-a-chrome-extension-with-figwheel-main.png
---For a better visualization, itβs recommended to set a cover image for each post (although itβs not mandatory). I personally go to UnsplashΒ or PexelsΒ to select covers (choose the small size).
If you donβt specify a cover image, Dream will use one of the predefined images as a placeholder in the summary card.
To disable this behavior, set noDefaultSummaryCover to true.
Image Optimization
Hugo >= 0.97.0 is required.
Dream will transform summary images to webp format automatically if you are using page bundlesΒ to organize your posts. This will make the first load of your site faster.
The way it works is that Dream will look for the presence of the specified cover image in the page resourcesΒ . If it exists, the image is processed.
For example, you can organize your posts like this:
content
βββ posts
β βββ post-1
β β βββ index.md
β β βββ cover.jpgThen in the front matter of index.md:
---
cover: cover.jpg
images:
- cover.jpg
---