summaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorRafi Zadanly <zadanlyr@gmail.com>2023-03-29 17:02:57 +0700
committerRafi Zadanly <zadanlyr@gmail.com>2023-03-29 17:02:57 +0700
commit72329fb20c3bc7703590b85bd0c42ea32e7cfe61 (patch)
treea5ad3074010154cf6d105a81f1175da844c0a798 /src/core
parent0d42449cdd6e53cb8e98555660aefee81997a9d3 (diff)
SEO
Diffstat (limited to 'src/core')
-rw-r--r--src/core/components/Seo.jsx33
1 files changed, 28 insertions, 5 deletions
diff --git a/src/core/components/Seo.jsx b/src/core/components/Seo.jsx
index e688077e..0e224c19 100644
--- a/src/core/components/Seo.jsx
+++ b/src/core/components/Seo.jsx
@@ -1,10 +1,33 @@
-import Head from 'next/head'
+import { NextSeo } from 'next-seo'
+import { useRouter } from 'next/router'
+
+const Seo = ({ ...props }) => {
+ const router = useRouter()
+
+ const { additionalMetaTags = [], openGraph = [], title = '' } = props
-const Seo = ({ title }) => {
return (
- <Head>
- <title>{title}</title>
- </Head>
+ <NextSeo
+ defaultTitle='Indoteknik.com: B2B Industrial Supply & Solution'
+ canonical={process.env.NEXT_PUBLIC_SELF_HOST + router.asPath}
+ description={title}
+ {...props}
+ openGraph={{
+ siteName: 'Indoteknik.com',
+ ...openGraph
+ }}
+ additionalMetaTags={[
+ {
+ property: 'fb:app_id',
+ content: '270830718811'
+ },
+ {
+ property: 'fb:page_id',
+ content: '101759953569'
+ },
+ ...additionalMetaTags
+ ]}
+ />
)
}