hugo-coder
hugo-coder copied to clipboard
Get featuredImage from assets/ dir or page bundles
Prerequisites
Put an x
into the box(es) that apply:
- [x] This pull request adds a feature.
Description
This change allows the featuredImage
front matter param to reference images in both the assets/
directory as well as in a page bundle
The order of arguments in the or
statement implies a preference for bundled resources first, then the assets directory, then the static directory, which is in order of decreasing specificity and puts the assets pipeline first, if a resource can be found there.
Issues Resolved
https://github.com/luizdepra/hugo-coder/issues/758
Checklist
Put an x
into the box(es) that apply:
General
- [x] Describe what changes are being made
- [x] Explain why and how the changes were necessary and implemented respectively
- [x] Reference issue with
#<ISSUE_NO>
if applicable
Contributors
- [x] Add yourself to
CONTRIBUTORS.md
if you aren't on it already