feat: Enhance SEO/SMO with dynamic Open Graph tags#426
feat: Enhance SEO/SMO with dynamic Open Graph tags#426sbglasius merged 1 commit intoapache:masterfrom
Conversation
There was a problem hiding this comment.
@Divyapahuja31 If you rebase this PR then I will approve it.
sure |
98dfc39 to
de26993
Compare
jdaugherty
left a comment
There was a problem hiding this comment.
Can you please restore the original spacing to the document.html, etc? These changes are separate from the PR and should not be included.
de26993 to
f56ebb2
Compare
Done! I have restored the original spacing in document.html and removed the unrelated lazy-loading changes. The PR now focus strictly on the dynamic Open Graph tags as originally intended. Thanks for catching that! |
jdaugherty
left a comment
There was a problem hiding this comment.
@sbglasius if you're good, i'm ok to merge this.
Description
This PR significantly improves the website's SEO (Search Engine Optimization) and SMO (Social Media Optimization) by implementing dynamic Open Graph meta tags.
The Problem
Previously, the
og:urlandog:imagetags were hardcoded or static. This meant that when users shared specific blog posts or documentation pages on platforms like Twitter, LinkedIn, or Slack, the preview often displayed generic information or the wrong image, leading to poor user engagement.The Solution
I have updated
RenderSiteTask.groovyandBlogTask.groovyto dynamically generate metadata:og:url: Each specific page now reports its permalink instead of the site root, ensuring social platforms point users to the correct destination.og:image:og:image:widthandog:image:heighttags (300x300), which were causing distortion for non-square images.Impact
These changes ensure that all shared links from the Grails website look professional, relevant, and visually appealing, directly improving the brand's presence on social media.
Checklist
og:urlpoints to the correct permalink on blog posts and pages.og:imagecorrectly picks up blog post images.