Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Featured image detection refactoring: #462

Merged
merged 1 commit into from
Dec 23, 2021

Conversation

regisphilibert
Copy link
Member

@regisphilibert regisphilibert commented Dec 23, 2021

We look for .Params.featured_image
If found > we use that as URL
If we find a Page resource matching the value of the above, we use its .RelPermalink
If none of the above we look for an resource whose filepath contains featured or cover and use its .RelPermalink if found

Fixes #233
Fixes #407

Thanks to @sgharms @pmorch

We look for .Params.featured_image
If found > we use that as URL
If we find a Page resource matching the value of the above, we use its .RelPermalink
If none of the above we look for an resource whose filepath contains `featured` or `cover` and use its .RelPermalink if found

Fixes #233
Fixes #407
@regisphilibert regisphilibert merged commit 1f11fbe into master Dec 23, 2021
Remicck pushed a commit to Remicck/gohugo-theme-ananke that referenced this pull request Mar 7, 2022
We look for .Params.featured_image
If found > we use that as URL
If we find a Page resource matching the value of the above, we use its .RelPermalink
If none of the above we look for an resource whose filepath contains `featured` or `cover` and use its .RelPermalink if found

Fixes theNewDynamic#233
Fixes theNewDynamic#407
@davidsneighbour davidsneighbour deleted the 233-improve-featured-image branch October 21, 2024 00:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Featured image requires absolute path
1 participant