Skip to content

feat(config): add SEO headTags, metadata, and structured data#318

Merged
kmesh-bot merged 3 commits into
kmesh-net:mainfrom
kunal-yelgate:feat/seo-metadata-docusaurus
Jul 4, 2026
Merged

feat(config): add SEO headTags, metadata, and structured data#318
kmesh-bot merged 3 commits into
kmesh-net:mainfrom
kunal-yelgate:feat/seo-metadata-docusaurus

Conversation

@kunal-yelgate

Copy link
Copy Markdown
Contributor

Adds global SEO configuration to docusaurus.config.js including Open Graph, Twitter Cards, and JSON-LD structured data.

Changes

  • headTags: Canonical link, meta description, OG tags, Twitter Card tags, Organization JSON-LD
  • themeConfig.metadata: Keywords, author, robots directives
  • image: Default social sharing card (img/kmesh-social-card.png)

Why

Pages currently lack any SEO metadata, causing poor search rankings and broken social previews.

Testing

  • Local build passes
  • All tags verified in page <head> via dev tools

Fixes #317

@netlify

netlify Bot commented Jun 25, 2026

Copy link
Copy Markdown

Deploy Preview for kmesh-net ready!

Name Link
🔨 Latest commit 6a172ef
🔍 Latest deploy log https://app.netlify.com/projects/kmesh-net/deploys/6a43d0294f293c0008f5ae0a
😎 Deploy Preview https://deploy-preview-318--kmesh-net.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@kmesh-bot

Copy link
Copy Markdown
Collaborator

Welcome @kunal-yelgate! It looks like this is your first PR to kmesh-net/website 🎉

@kunal-yelgate kunal-yelgate force-pushed the feat/seo-metadata-docusaurus branch from a3fa9de to a397405 Compare June 25, 2026 12:12

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates docusaurus.config.js to add a tagline, social sharing image, structured JSON-LD data, and various SEO metadata tags. The review feedback highlights a critical SEO issue where a hardcoded global canonical link in headTags would incorrectly point all subpages to the homepage. Additionally, it recommends moving global meta tags from headTags to themeConfig.metadata to leverage Docusaurus's built-in metadata management and allow page-specific overrides.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread docusaurus.config.js Outdated
Comment on lines +23 to +66
headTags: [
{
tagName: "link",
attributes: {
rel: "canonical",
href: "https://kmesh.net",
},
},
{
tagName: "meta",
attributes: {
name: "description",
content:
"Kmesh is a high-performance, sidecarless service mesh dataplane based on eBPF and programmable kernel for cloud-native applications.",
},
},
{
tagName: "meta",
attributes: {
property: "og:type",
content: "website",
},
},
{
tagName: "meta",
attributes: {
property: "og:site_name",
content: "Kmesh",
},
},
{
tagName: "meta",
attributes: {
name: "twitter:card",
content: "summary_large_image",
},
},
{
tagName: "meta",
attributes: {
name: "twitter:site",
content: "@Kmesh_net",
},
},

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

SEO & Docusaurus Best Practices Improvements

  1. Remove Hardcoded Canonical Link: Docusaurus automatically generates the correct canonical URL (<link rel="canonical" href="..." />) for every page of your site using the global url and baseUrl configuration (which are already set). Hardcoding a global canonical link to https://kmesh.net in headTags will apply to all pages (e.g., documentation pages, blog posts), pointing their canonical URLs back to the homepage. This is a severe SEO issue as search engines will index only the homepage and ignore all other pages.
  2. Move Meta Tags to themeConfig.metadata: Using headTags injects these tags statically into every page, which can result in duplicate tags (e.g., multiple <meta name="description"> tags) when individual pages or blog posts define their own descriptions or custom metadata. Defining them in themeConfig.metadata allows Docusaurus to manage them properly and lets individual pages override them seamlessly.

Let's remove the canonical link and move the meta tags to themeConfig.metadata.

Suggested change
headTags: [
{
tagName: "link",
attributes: {
rel: "canonical",
href: "https://kmesh.net",
},
},
{
tagName: "meta",
attributes: {
name: "description",
content:
"Kmesh is a high-performance, sidecarless service mesh dataplane based on eBPF and programmable kernel for cloud-native applications.",
},
},
{
tagName: "meta",
attributes: {
property: "og:type",
content: "website",
},
},
{
tagName: "meta",
attributes: {
property: "og:site_name",
content: "Kmesh",
},
},
{
tagName: "meta",
attributes: {
name: "twitter:card",
content: "summary_large_image",
},
},
{
tagName: "meta",
attributes: {
name: "twitter:site",
content: "@Kmesh_net",
},
},
headTags: [

Comment thread docusaurus.config.js
Comment on lines +152 to +166
metadata: [
{
name: "keywords",
content:
"Kmesh, service mesh, eBPF, dataplane, Kubernetes, sidecarless, cloud-native, CNCF, high-performance networking",
},
{
name: "author",
content: "Kmesh Community",
},
{
name: "robots",
content: "index, follow",
},
],

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Move the global meta tags (description, og:type, og:site_name, twitter:card, and twitter:site) from headTags to themeConfig.metadata so that Docusaurus can manage them properly and allow page-specific overrides.

      metadata: [
        {
          name: "description",
          content:
            "Kmesh is a high-performance, sidecarless service mesh dataplane based on eBPF and programmable kernel for cloud-native applications.",
        },
        {
          property: "og:type",
          content: "website",
        },
        {
          property: "og:site_name",
          content: "Kmesh",
        },
        {
          name: "twitter:card",
          content: "summary_large_image",
        },
        {
          name: "twitter:site",
          content: "@Kmesh_net",
        },
        {
          name: "keywords",
          content:
            "Kmesh, service mesh, eBPF, dataplane, Kubernetes, sidecarless, cloud-native, CNCF, high-performance networking",
        },
        {
          name: "author",
          content: "Kmesh Community",
        },
        {
          name: "robots",
          content: "index, follow",
        },
      ],

@yashisrani

Copy link
Copy Markdown
Contributor

@kunal-yelgate please fix this build errors

Screenshot 2026-06-29 at 10 40 07 PM

…urus config

Signed-off-by: kunal_yelgate <kunalyelgatew@gmail.com>
Signed-off-by: kunal_yelgate <kunalyelgatew@gmail.com>
Signed-off-by: kunal_yelgate <kunalyelgatew@gmail.com>
@kunal-yelgate kunal-yelgate force-pushed the feat/seo-metadata-docusaurus branch from a9dafd1 to 6a172ef Compare June 30, 2026 14:18
@kunal-yelgate

Copy link
Copy Markdown
Contributor Author

Hey @yashisrani, I fixed the build error. The project now builds successfully for both the default locale and the zh locale:

[SUCCESS] Generated static files in "build".
[INFO] [zh] Creating an optimized production build...
[SUCCESS] Generated static files in "build\zh".
[INFO] Use `npm run serve` command to test your build locally.

The build is completing successfully now.

@jayesh9747

Copy link
Copy Markdown
Collaborator

/lgtm

@kmesh-bot kmesh-bot added the lgtm label Jul 4, 2026
@jayesh9747 jayesh9747 added this pull request to the merge queue Jul 4, 2026
@jayesh9747

Copy link
Copy Markdown
Collaborator

/lgtm

@kmesh-bot

Copy link
Copy Markdown
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jayesh9747

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to no response for status checks Jul 4, 2026
@kmesh-bot kmesh-bot merged commit 0b5da86 into kmesh-net:main Jul 4, 2026
12 checks passed
@kunal-yelgate kunal-yelgate deleted the feat/seo-metadata-docusaurus branch July 4, 2026 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SEO: Add Complete Metadata to Docusaurus Pages for Search Engine Optimization

4 participants