This is an automated email from the ASF dual-hosted git repository.
baoyuan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-website.git
The following commit(s) were added to refs/heads/master by this push:
new 3925efeed33 feat(seo): add BlogPosting JSON-LD structured data to blog
posts (#2018)
3925efeed33 is described below
commit 3925efeed33d2734290b744a53f1106564da94c2
Author: Ming Wen <[email protected]>
AuthorDate: Mon Apr 13 17:46:01 2026 +0800
feat(seo): add BlogPosting JSON-LD structured data to blog posts (#2018)
---
blog/src/theme/BlogPostPage/index.tsx | 31 +++++++++++++++++++++++++++++++
1 file changed, 31 insertions(+)
diff --git a/blog/src/theme/BlogPostPage/index.tsx
b/blog/src/theme/BlogPostPage/index.tsx
index d0a245f6eb6..874d3b0b8a9 100644
--- a/blog/src/theme/BlogPostPage/index.tsx
+++ b/blog/src/theme/BlogPostPage/index.tsx
@@ -133,6 +133,37 @@ const BlogPostPage = (props: Props): JSX.Element => {
{tags.length > 0 && (
<meta property="article:tag" content={tags.map((tag) =>
tag.label).join(',')} />
)}
+ <script type="application/ld+json">
+ {JSON.stringify({
+ '@context': 'https://schema.org',
+ '@type': 'BlogPosting',
+ headline: title,
+ description,
+ datePublished: date,
+ ...(image && { image }),
+ author: authors.map((author) => ({
+ '@type': 'Person',
+ name: author.name,
+ ...(author.url && { url: author.url }),
+ ...(author.imageURL && { image: author.imageURL }),
+ })),
+ ...(tags.length > 0 && {
+ keywords: tags.map((tag) => tag.label).join(', '),
+ }),
+ publisher: {
+ '@type': 'Organization',
+ name: 'Apache APISIX',
+ logo: {
+ '@type': 'ImageObject',
+ url: 'https://apisix.apache.org/img/logo2.svg',
+ },
+ },
+ mainEntityOfPage: {
+ '@type': 'WebPage',
+ '@id': metadata.permalink,
+ },
+ })}
+ </script>
</Seo>
<BlogPostItem frontMatter={frontMatter} assets={assets}
metadata={metadata} isBlogPostPage>