mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2025-07-21 11:21:16 -04:00
remove dependency on uglify-js
This commit is contained in:
@@ -3,6 +3,8 @@ import { meJpg, faviconPng, faviconIco, appleTouchIconPng } from "./favicons";
|
||||
|
||||
import type { DefaultSeoProps, SocialProfileJsonLdProps, ArticleJsonLdProps } from "next-seo";
|
||||
|
||||
const baseUrl = process.env.NEXT_PUBLIC_BASE_URL || `https://${config.siteDomain}`;
|
||||
|
||||
// Most of this file simply takes the data already defined in ./config.js and translates it into objects that are
|
||||
// compatible with next-seo's props:
|
||||
// https://github.com/garmeeh/next-seo#default-seo-configuration
|
||||
@@ -17,7 +19,7 @@ export const defaultSeo: DefaultSeoProps = {
|
||||
type: "website",
|
||||
images: [
|
||||
{
|
||||
url: `${process.env.BASE_URL}${meJpg.src}`,
|
||||
url: `${baseUrl}${meJpg.src}`,
|
||||
alt: `${config.siteName} – ${config.shortDescription}`,
|
||||
},
|
||||
],
|
||||
@@ -95,9 +97,9 @@ export const defaultSeo: DefaultSeoProps = {
|
||||
export const socialProfileJsonLd: SocialProfileJsonLdProps = {
|
||||
type: "Person",
|
||||
name: config.authorName,
|
||||
url: `${process.env.BASE_URL}/`,
|
||||
url: `${baseUrl}/`,
|
||||
sameAs: [
|
||||
`${process.env.BASE_URL}/`,
|
||||
`${baseUrl}/`,
|
||||
`https://github.com/${config.authorSocial?.github}`,
|
||||
`https://keybase.io/${config.authorSocial?.keybase}`,
|
||||
`https://twitter.com/${config.authorSocial?.twitter}`,
|
||||
@@ -114,8 +116,8 @@ export const socialProfileJsonLd: SocialProfileJsonLdProps = {
|
||||
export const articleJsonLd: Pick<ArticleJsonLdProps, "authorName" | "publisherName" | "publisherLogo"> = {
|
||||
authorName: {
|
||||
name: config.authorName,
|
||||
url: `${process.env.BASE_URL}/`,
|
||||
url: `${baseUrl}/`,
|
||||
},
|
||||
publisherName: config.siteName,
|
||||
publisherLogo: `${process.env.BASE_URL}${meJpg.src}`,
|
||||
publisherLogo: `${baseUrl}${meJpg.src}`,
|
||||
};
|
||||
|
Reference in New Issue
Block a user