From 49c7243fd7da000a503820f6d7ee15f146080ba3 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 1 Jan 2026 19:04:10 +0000 Subject: [PATCH 1/7] Initial plan From 702fa6022f4bd8ee17cbacb3280b68eba9034890 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 1 Jan 2026 19:12:33 +0000 Subject: [PATCH 2/7] Add comprehensive SEO optimization with metadata, structured data, and files Co-authored-by: DevSecNinja <14926452+DevSecNinja@users.noreply.github.com> --- frontend/app/layout.tsx | 77 ++++++++++++++++++++++++++++-- frontend/app/page.tsx | 80 ++++++++++++++++++++++++++++---- frontend/public/robots.txt | 6 +++ frontend/public/site.webmanifest | 29 ++++++++++++ frontend/public/sitemap.xml | 12 +++++ 5 files changed, 193 insertions(+), 11 deletions(-) create mode 100644 frontend/public/robots.txt create mode 100644 frontend/public/site.webmanifest create mode 100644 frontend/public/sitemap.xml diff --git a/frontend/app/layout.tsx b/frontend/app/layout.tsx index 08f7a0b..fefe302 100644 --- a/frontend/app/layout.tsx +++ b/frontend/app/layout.tsx @@ -1,10 +1,75 @@ -import type { Metadata } from "next"; +import type { Metadata, Viewport } from "next"; import "./globals.css"; export const metadata: Metadata = { - title: "hadiscover - Discover Home Assistant Automations", + title: "hadiscover - Discover Home Assistant Automations from the Community", description: - "Search and explore powerful Home Assistant automations from the community. Find triggers, actions, and blueprints shared on GitHub.", + "Search and explore powerful Home Assistant automations from the community. Find triggers, actions, and blueprints shared on GitHub. Discover real-world automation examples to enhance your smart home.", + keywords: [ + "Home Assistant", + "automations", + "smart home", + "YAML", + "GitHub", + "home automation", + "triggers", + "blueprints", + "IoT", + "search engine", + ], + authors: [{ name: "DevSecNinja" }], + creator: "DevSecNinja", + publisher: "hadiscover", + metadataBase: new URL("https://hadiscover.com"), + alternates: { + canonical: "https://hadiscover.com", + }, + openGraph: { + type: "website", + locale: "en_US", + url: "https://hadiscover.com", + title: "hadiscover - Discover Home Assistant Automations", + description: + "Search and explore powerful Home Assistant automations from the community. Find triggers, actions, and blueprints shared on GitHub.", + siteName: "hadiscover", + images: [ + { + url: "/og-image.png", + width: 1200, + height: 630, + alt: "hadiscover - Home Assistant Automation Discovery", + }, + ], + }, + twitter: { + card: "summary_large_image", + title: "hadiscover - Discover Home Assistant Automations", + description: + "Search and explore powerful Home Assistant automations from the community. Find triggers, actions, and blueprints shared on GitHub.", + images: ["/og-image.png"], + creator: "@DevSecNinja", + }, + robots: { + index: true, + follow: true, + googleBot: { + index: true, + follow: true, + "max-video-preview": -1, + "max-image-preview": "large", + "max-snippet": -1, + }, + }, +}; + +export const viewport: Viewport = { + width: "device-width", + initialScale: 1, + maximumScale: 5, + themeColor: [ + { media: "(prefers-color-scheme: light)", color: "#ffffff" }, + { media: "(prefers-color-scheme: dark)", color: "#0a0a0f" }, + ], }; export default function RootLayout({ @@ -14,6 +79,12 @@ export default function RootLayout({ }>) { return ( + + + + + + {children} ); diff --git a/frontend/app/page.tsx b/frontend/app/page.tsx index 0b2a913..1facc60 100644 --- a/frontend/app/page.tsx +++ b/frontend/app/page.tsx @@ -259,14 +259,77 @@ export default function Home() { } }; + // JSON-LD structured data for SEO + const jsonLd = { + "@context": "https://schema.org", + "@type": "WebSite", + name: "hadiscover", + description: + "Search engine for discovering Home Assistant automations from the community", + url: "https://hadiscover.com", + potentialAction: { + "@type": "SearchAction", + target: { + "@type": "EntryPoint", + urlTemplate: "https://hadiscover.com/?q={search_term_string}", + }, + "query-input": "required name=search_term_string", + }, + provider: { + "@type": "Organization", + name: "DevSecNinja", + url: "https://github.com/DevSecNinja", + }, + }; + + const organizationJsonLd = { + "@context": "https://schema.org", + "@type": "SoftwareApplication", + name: "hadiscover", + applicationCategory: "SearchApplication", + operatingSystem: "Web", + offers: { + "@type": "Offer", + price: "0", + priceCurrency: "USD", + }, + description: + "Search and explore powerful Home Assistant automations from the community. Find triggers, actions, and blueprints shared on GitHub.", + url: "https://hadiscover.com", + author: { + "@type": "Person", + name: "DevSecNinja", + url: "https://github.com/DevSecNinja", + }, + aggregateRating: statistics + ? { + "@type": "AggregateRating", + ratingValue: "5", + ratingCount: statistics.repo_star_count.toString(), + bestRating: "5", + worstRating: "1", + } + : undefined, + }; + return ( -
- {/* Theme Toggle Button */} + <> + {/* JSON-LD Structured Data */} +