From 5627b2daafd54d3f9fe607014b13364db7298f07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82?= Date: Sun, 28 Jan 2024 21:34:54 +0100 Subject: [PATCH] feat: add google site verification --- .env.example | 1 + src/app/layout.tsx | 3 +++ src/lib/constant.ts | 5 ++++- 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.env.example b/.env.example index 3d4a03e..267d88e 100644 --- a/.env.example +++ b/.env.example @@ -1,3 +1,4 @@ # Duplicate this to .env.local NEXT_PUBLIC_SITE_URL='https://example.com' +NEXT_PUBLIC_GOOGLE_SITE_VERIFICATION_ID='xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' diff --git a/src/app/layout.tsx b/src/app/layout.tsx index e05f597..328e00e 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -24,6 +24,9 @@ export const metadata: Metadata = { shortcut: '/favicon/favicon-16x16.png', apple: '/favicon/apple-touch-icon.png', }, + verification: { + google: siteConfig.googleSiteVerificationId, + }, openGraph: { url: siteConfig.url, title: siteConfig.title, diff --git a/src/lib/constant.ts b/src/lib/constant.ts index 906f47a..8c23a8d 100644 --- a/src/lib/constant.ts +++ b/src/lib/constant.ts @@ -4,6 +4,8 @@ export const siteConfig = { 'It is a Next.js starter template powered by TypeScript, styled with Tailwind CSS and Shadcn/ui. Features include Dark Mode, SEO optimization, and pre-configured eslint, prettier, husky, and lint-staged settings. Jumpstart your project with efficiency and style.', keywords: [ 'Next.js', + 'Next.js starter', + 'Next.js boilerplate', 'Tailwind CSS', 'TypeScript', 'Dark Mode', @@ -16,7 +18,6 @@ export const siteConfig = { 'Github actions', 'Web Development', 'Starter Template', - 'Next.js starter', 'Frontend', 'React', 'JavaScript', @@ -27,4 +28,6 @@ export const siteConfig = { 'Code Quality', ], url: process.env.NEXT_PUBLIC_SITE_URL || 'https://example.com', + googleSiteVerificationId: + process.env.NEXT_PUBLIC_GOOGLE_SITE_VERIFICATION_ID || '', };