Closed lakebayagency closed 1 year ago
Is there any reason not to just use this as the condition?
{#if post.excerpt}
Only my ignorance! 🙂
After some consideration, I don't think this should be fixed, since the excerpt data is also used by the meta tags present on the post pages. My feeling is that the project probably shouldn't treat a frontmatter prop as optional when it goes into the SEO of the published site.
Naturally, it's just a starter and authors can remove it if they like. I think this should probably remain as the "happy path" for the time being, though.
Simple fix to skip rendering "undefined" if your post doesn't have an excerpt: