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

Empty img element when there is no featured image #117

Open
rmens opened this issue Oct 28, 2020 · 3 comments
Open

Empty img element when there is no featured image #117

rmens opened this issue Oct 28, 2020 · 3 comments

Comments

@rmens
Copy link

rmens commented Oct 28, 2020

When a post has no featured image, there is an empty <img src=""> element in each single post. Singe.twig seems to assume there is always a featured image on a post, which is not always true. There should probably be a check on that.

@jarednova
Copy link
Member

Great call @rmens! Seems like it's a quick fix, but I want to give you first crack at the PR opportunity. Could you handle the fame and glory?

@AshleyRedman
Copy link

I feel that this sort of thing is project-specific. It's very simple to add a conditional to render this if a featured image is present or not, and as a starter theme, it does assume a featured image would be present. Similarly, it is project-specific that you may define a default featured image if one isn't selected as well as any other attr that the image may have.

@Levdbas
Copy link
Member

Levdbas commented Nov 23, 2023

I think A small check to add to a single page is not really that hard to do and gives a good example. I will mark this as an enhancement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants