Added analytics
This commit is contained in:
parent
70a5cbae91
commit
a87d886785
|
@ -92,6 +92,8 @@ NEXT_PUBLIC_URL_IMG=https://url-to.img-accords-library.com
|
||||||
NEXT_PUBLIC_URL_WATCH=https://url-to.watch-accords-library.com
|
NEXT_PUBLIC_URL_WATCH=https://url-to.watch-accords-library.com
|
||||||
NEXT_PUBLIC_URL_SELF=https://url-to-front-accords-library.com
|
NEXT_PUBLIC_URL_SELF=https://url-to-front-accords-library.com
|
||||||
NEXT_PUBLIC_URL_SEARCH=https://url-to.search-accords-library.com
|
NEXT_PUBLIC_URL_SEARCH=https://url-to.search-accords-library.com
|
||||||
|
NEXT_PUBLIC_UMAMI_URL=https://url-to.umami-accords-library.com
|
||||||
|
NEXT_PUBLIC_UMAMI_ID=abcdef0123456789
|
||||||
```
|
```
|
||||||
|
|
||||||
Run in dev mode:
|
Run in dev mode:
|
||||||
|
|
|
@ -211,34 +211,35 @@ export const AppLayout = ({
|
||||||
<title>{openGraph.title}</title>
|
<title>{openGraph.title}</title>
|
||||||
<meta name="description" content={openGraph.description} />
|
<meta name="description" content={openGraph.description} />
|
||||||
|
|
||||||
<meta name="twitter:title" content={openGraph.title}></meta>
|
<meta name="twitter:title" content={openGraph.title} />
|
||||||
<meta
|
<meta name="twitter:description" content={openGraph.description} />
|
||||||
name="twitter:description"
|
<meta name="twitter:card" content="summary_large_image" />
|
||||||
content={openGraph.description}
|
<meta name="twitter:image" content={openGraph.thumbnail.image} />
|
||||||
></meta>
|
|
||||||
<meta name="twitter:card" content="summary_large_image"></meta>
|
|
||||||
<meta name="twitter:image" content={openGraph.thumbnail.image}></meta>
|
|
||||||
|
|
||||||
<meta property="og:title" content={openGraph.title} />
|
<meta property="og:title" content={openGraph.title} />
|
||||||
<meta property="og:description" content={openGraph.description} />
|
<meta property="og:description" content={openGraph.description} />
|
||||||
<meta property="og:image" content={openGraph.thumbnail.image}></meta>
|
<meta property="og:image" content={openGraph.thumbnail.image} />
|
||||||
<meta
|
<meta
|
||||||
property="og:image:secure_url"
|
property="og:image:secure_url"
|
||||||
content={openGraph.thumbnail.image}
|
content={openGraph.thumbnail.image}
|
||||||
></meta>
|
/>
|
||||||
<meta
|
<meta
|
||||||
property="og:image:width"
|
property="og:image:width"
|
||||||
content={openGraph.thumbnail.width.toString()}
|
content={openGraph.thumbnail.width.toString()}
|
||||||
></meta>
|
/>
|
||||||
<meta
|
<meta
|
||||||
property="og:image:height"
|
property="og:image:height"
|
||||||
content={openGraph.thumbnail.height.toString()}
|
content={openGraph.thumbnail.height.toString()}
|
||||||
></meta>
|
/>
|
||||||
<meta
|
<meta property="og:image:alt" content={openGraph.thumbnail.alt} />
|
||||||
property="og:image:alt"
|
<meta property="og:image:type" content="image/jpeg" />
|
||||||
content={openGraph.thumbnail.alt}
|
|
||||||
></meta>
|
<script
|
||||||
<meta property="og:image:type" content="image/jpeg"></meta>
|
async
|
||||||
|
defer
|
||||||
|
data-website-id={process.env.NEXT_PUBLIC_UMAMI_ID}
|
||||||
|
src={`${process.env.NEXT_PUBLIC_UMAMI_URL}/umami.js`}
|
||||||
|
/>
|
||||||
</Head>
|
</Head>
|
||||||
|
|
||||||
{/* Background when navbar is opened */}
|
{/* Background when navbar is opened */}
|
||||||
|
|
|
@ -190,6 +190,9 @@ const Revalidate = (
|
||||||
paths.push(`/library/${body.entry.library_item.slug}`);
|
paths.push(`/library/${body.entry.library_item.slug}`);
|
||||||
paths.push(`/library/${body.entry.library_item.slug}/scans`);
|
paths.push(`/library/${body.entry.library_item.slug}/scans`);
|
||||||
}
|
}
|
||||||
|
if (body.entry.content) {
|
||||||
|
paths.push(`/contents/${body.entry.content.slug}`);
|
||||||
|
}
|
||||||
serverRuntimeConfig.locales?.map((locale: string) => {
|
serverRuntimeConfig.locales?.map((locale: string) => {
|
||||||
if (body.entry.library_item) {
|
if (body.entry.library_item) {
|
||||||
paths.push(`/${locale}/library/${body.entry.library_item.slug}`);
|
paths.push(`/${locale}/library/${body.entry.library_item.slug}`);
|
||||||
|
@ -197,6 +200,9 @@ const Revalidate = (
|
||||||
`/${locale}/library/${body.entry.library_item.slug}/scans`
|
`/${locale}/library/${body.entry.library_item.slug}/scans`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
if (body.entry.content) {
|
||||||
|
paths.push(`/${locale}/contents/${body.entry.content.slug}`);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue