Skip to content

Conversation

@DYHARDx
Copy link

@DYHARDx DYHARDx commented Oct 29, 2025

Related issue: #1085

Summary

This pull request adds a complete SEO setup to help the website appear and rank properly on Google.
It includes sitemap creation, robots.txt configuration, meta tags, internal linking improvements, and initial Core Web Vitals optimization.
A few Markdown files were also refined using AI to make the documentation clearer and easier to read.

What’s Included

  • Added /sitemap.xml and linked it in robots.txt
  • Updated robots.txt with proper crawl rules
  • Improved meta titles, descriptions, and canonical links
  • Structured H1–H3 tags on key pages for better readability and keyword relevance
  • Optimized image alt text and URLs
  • Added basic JSON-LD schema (Organization / Website)
  • Made small performance improvements (defer scripts, preconnect, compress assets)
  • Ensured mobile responsiveness and proper viewport meta
  • Refined and reorganized several Markdown docs for better clarity (AI-assisted)

Checklist

  • Sitemap generated and referenced in robots.txt
  • Meta tags and descriptions added for all major pages
  • JSON-LD schema implemented
  • Image alt texts optimized
  • Mobile responsiveness confirmed
  • AI-assisted edits reviewed for clarity
  • Submit sitemap in Google Search Console
  • Perform full Lighthouse audit for Core Web Vitals
  • Monitor indexing and keyword ranking

How to Test

  1. Pull this branch and deploy to staging.
  2. Visit /sitemap.xml and /robots.txt to confirm setup.
  3. Inspect source for meta tags and JSON-LD schema.
  4. Run Lighthouse (mobile) and note performance scores.
  5. Review updated .md files for clarity and structure.

Notes for Maintainers

  • Google Search Console submission must be done by the site owner.
  • Further optimization may be needed for advanced CWV improvements.
  • Some Markdown edits were AI-assisted for clarity; human verification recommended.

@vercel
Copy link
Contributor

vercel bot commented Oct 29, 2025

@DYHARDx is attempting to deploy a commit to the recode Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions
Copy link

Thank you for submitting your pull request! 🙌 We'll review it as soon as possible. The estimated time for response is 5–8 hrs.

In the meantime, please provide all necessary screenshots and make sure you run - npm build run , command and provide a screenshot, a video recording, or an image of the update you made below, which helps speed up the review and assignment. If you have questions, reach out to LinkedIn. Your contributions are highly appreciated!😊

Note: I maintain the repo issue every day twice at 8:00 AM IST and 9:00 PM IST. If your PR goes stale for more than one day, you can tag and comment on this same issue by tagging @sanjay-kv.

We are here to help you on this journey of open source. Consistent 20 contributions are eligible for sponsorship 💰

🎁 check our list of amazing people we sponsored so far: GitHub Sponsorship. ✨

📚Your perks for contribution to this community 👇🏻

  1. Get free Consultation use code recode50 to get free: Mentorship for free.

  2. Get the Ebook for free use code recode at checkout: Data Science cheatsheet for Beginners.

  3. Check out this weekly Newsletter: Sanjay's Newsletter.

If there are any specific instructions or feedback regarding your PR, we'll provide them here. Thanks again for your contribution! 😊

@github-actions github-actions bot added hacktoberfest-accepted recode this is label for leaderboard level 1 10 points labels Oct 29, 2025
@github-actions github-actions bot added this to the recode:launch 3.0 milestone Oct 29, 2025
@github-actions
Copy link

✅ Synchronized metadata from Issue #1085:

  • Labels: level 1, recode, hacktoberfest-accepted
  • Milestone: recode:launch 3.0

Added a video tutorial link and community resources to README.
@github-actions
Copy link

✅ Synchronized metadata from Issue #1085:

  • Labels: level 1, recode, hacktoberfest-accepted
  • Milestone: recode:launch 3.0

Comment on lines +302 to +340
headTags: [
// Structured data for rich search results
{
tagName: "script",
attributes: {
type: "application/ld+json",
},
innerHTML: JSON.stringify({
"@context": "https://schema.org",
"@type": "Organization",
name: "Recode Hive",
url: "https://www.recodehive.com",
logo: "https://www.recodehive.com/img/logo.png",
sameAs: [
"https://github.com/recodehive",
"https://www.youtube.com/@recodehive",
"https://twitter.com/recodehive",
],
description:
"A community-driven platform for learning programming, coding tutorials, and developer resources.",
}),
},
// Preconnect to Google Analytics for performance
{
tagName: "link",
attributes: {
rel: "preconnect",
href: "https://www.google-analytics.com",
},
},
// Preconnect to Google Fonts if used
{
tagName: "link",
attributes: {
rel: "preconnect",
href: "https://fonts.googleapis.com",
},
},
],
Copy link
Contributor

Choose a reason for hiding this comment

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

The headTags and metadata arrays are incorrectly placed inside customFields where they won't be processed by Docusaurus. These configuration objects should be moved to the root level of the config or removed if their functionality is already covered by page-level Head components.

View Details
📝 Patch Details
diff --git a/docusaurus.config.ts b/docusaurus.config.ts
index df38619..1bdce19 100644
--- a/docusaurus.config.ts
+++ b/docusaurus.config.ts
@@ -273,71 +273,98 @@ const config: Config = {
     ],
   ],
 
-  // Global SEO metadata
-  customFields: {
-    metadata: [
-      {
+  // Global SEO head tags for all pages
+  headTags: [
+    // Global metadata
+    {
+      tagName: "meta",
+      attributes: {
         name: "keywords",
-        content:
-          "programming, coding, tutorials, open source, developer community, learning, education, tech",
+        content: "programming, coding, tutorials, open source, developer community, learning, education, tech",
       },
-      {
+    },
+    {
+      tagName: "meta",
+      attributes: {
         name: "description",
-        content:
-          "Recode Hive - A community-driven platform for learning programming, coding tutorials, and developer resources.",
+        content: "Recode Hive - A community-driven platform for learning programming, coding tutorials, and developer resources.",
       },
-      { name: "twitter:card", content: "summary_large_image" },
-      {
+    },
+    {
+      tagName: "meta",
+      attributes: {
+        name: "twitter:card",
+        content: "summary_large_image",
+      },
+    },
+    {
+      tagName: "meta",
+      attributes: {
         name: "twitter:title",
         content: "Recode Hive - Learn Programming and Coding",
       },
-      {
+    },
+    {
+      tagName: "meta",
+      attributes: {
         name: "twitter:description",
-        content:
-          "Join our community to learn programming, access coding tutorials, and connect with developers worldwide.",
+        content: "Join our community to learn programming, access coding tutorials, and connect with developers worldwide.",
       },
-      { property: "og:type", content: "website" },
-      { property: "og:site_name", content: "Recode Hive" },
-    ],
-    headTags: [
-      // Structured data for rich search results
-      {
-        tagName: "script",
-        attributes: {
-          type: "application/ld+json",
-        },
-        innerHTML: JSON.stringify({
-          "@context": "https://schema.org",
-          "@type": "Organization",
-          name: "Recode Hive",
-          url: "https://www.recodehive.com",
-          logo: "https://www.recodehive.com/img/logo.png",
-          sameAs: [
-            "https://github.com/recodehive",
-            "https://www.youtube.com/@recodehive",
-            "https://twitter.com/recodehive",
-          ],
-          description:
-            "A community-driven platform for learning programming, coding tutorials, and developer resources.",
-        }),
+    },
+    {
+      tagName: "meta",
+      attributes: {
+        property: "og:type",
+        content: "website",
       },
-      // Preconnect to Google Analytics for performance
-      {
-        tagName: "link",
-        attributes: {
-          rel: "preconnect",
-          href: "https://www.google-analytics.com",
-        },
+    },
+    {
+      tagName: "meta",
+      attributes: {
+        property: "og:site_name",
+        content: "Recode Hive",
       },
-      // Preconnect to Google Fonts if used
-      {
-        tagName: "link",
-        attributes: {
-          rel: "preconnect",
-          href: "https://fonts.googleapis.com",
-        },
+    },
+    // Structured data for rich search results
+    {
+      tagName: "script",
+      attributes: {
+        type: "application/ld+json",
       },
-    ],
+      innerHTML: JSON.stringify({
+        "@context": "https://schema.org",
+        "@type": "Organization",
+        name: "Recode Hive",
+        url: "https://www.recodehive.com",
+        logo: "https://www.recodehive.com/img/logo.png",
+        sameAs: [
+          "https://github.com/recodehive",
+          "https://www.youtube.com/@recodehive",
+          "https://twitter.com/recodehive",
+        ],
+        description:
+          "A community-driven platform for learning programming, coding tutorials, and developer resources.",
+      }),
+    },
+    // Preconnect to Google Analytics for performance
+    {
+      tagName: "link",
+      attributes: {
+        rel: "preconnect",
+        href: "https://www.google-analytics.com",
+      },
+    },
+    // Preconnect to Google Fonts if used
+    {
+      tagName: "link",
+      attributes: {
+        rel: "preconnect",
+        href: "https://fonts.googleapis.com",
+      },
+    },
+  ],
+
+  customFields: {
     gitToken: process.env.DOCUSAURUS_GIT_TOKEN,
     // Shopify credentials for merch store
     SHOPIFY_STORE_DOMAIN:

Analysis

headTags and metadata incorrectly placed in customFields instead of root config

What fails: Global SEO tags (Organization JSON-LD schema, preconnect directives, and meta tags) in customFields.headTags and customFields.metadata are not processed by Docusaurus, preventing injection into HTML <head> sections across all pages.

How to reproduce:

npm run build
grep "application/ld+json" build/index.html  # No results found

Result: Organization schema and global meta tags missing from built HTML files. Only individual page-level SEO tags appear.

Expected: According to Docusaurus headTags documentation, headTags should be at root config level for proper HTML injection. After moving to root level, all tags appear correctly in built HTML.

@sanjay-kv
Copy link
Member

Added /sitemap.xml and linked it in robots.txt
Updated robots.txt with proper crawl rules

there is so many files not related especially blog post , lets stick to the real issue and remove unecessary doc files.

@sanjay-kv sanjay-kv added the under review Review under the maintainers or the admins label Oct 30, 2025
@DYHARDx
Copy link
Author

DYHARDx commented Oct 31, 2025

@sanjay-kv i added blog files because website in have no data for ranking google patch website data then ranking , if you want to remove then ok i will remove this

@iitzIrFan iitzIrFan requested review from iitzIrFan and sanjay-kv and removed request for sanjay-kv October 31, 2025 20:35
@iitzIrFan iitzIrFan moved this to In Progress in @recode-web Oct 31, 2025
@iitzIrFan iitzIrFan linked an issue Oct 31, 2025 that may be closed by this pull request
@sanjay-kv sanjay-kv closed this Nov 2, 2025
@github-project-automation github-project-automation bot moved this from In Progress to Done in @recode-web Nov 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hacktoberfest-accepted level 1 10 points recode this is label for leaderboard under review Review under the maintainers or the admins

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

🚀 Website Not Appearing in Google Search Results

2 participants