mirror of
https://github.com/SantaSpeen/santaspeen.ru-blog.git
synced 2025-07-01 23:36:26 +00:00
Fixes for .env
This commit is contained in:
parent
06bcbd063d
commit
b9caa21536
16
.env.example
16
.env.example
@ -2,14 +2,12 @@ ALGOLIA_APP_ID=
|
|||||||
ALGOLIA_API_KEY=
|
ALGOLIA_API_KEY=
|
||||||
ALGOLIA_INDEX_NAME=
|
ALGOLIA_INDEX_NAME=
|
||||||
|
|
||||||
GISCUS_DISCUSSION_CATEGORY=
|
COUNTER_GOOGLE=
|
||||||
GISCUS_DISCUSSION_CATEGORY_ID=
|
COUNTER_YANDEX=
|
||||||
GISCUS_PROJECT_ID=
|
|
||||||
|
|
||||||
GOOGLE_ANALYTICS_TAG_ID=
|
|
||||||
|
|
||||||
ORGANIZATION_NAME=
|
|
||||||
REPOSITORY_NAME=
|
|
||||||
|
|
||||||
|
SITE_URL=
|
||||||
SITE_TITLE=
|
SITE_TITLE=
|
||||||
SITE_URL=
|
SITE_ORANIZATION_NAME=
|
||||||
|
SITE_PROJECT_NAME=
|
||||||
|
|
||||||
|
# GISCUS settings in /src/theme/BlogPostItem.jsx
|
||||||
|
@ -8,15 +8,14 @@ const darkTheme = themes.dracula;
|
|||||||
|
|
||||||
/** @type {import('@docusaurus/types').Config} */
|
/** @type {import('@docusaurus/types').Config} */
|
||||||
const config = {
|
const config = {
|
||||||
title: 'SantaSpeen',
|
title: process.env.SITE_TITLE,
|
||||||
tagline: 'Personal Blog',
|
tagline: 'Personal Blog',
|
||||||
favicon: 'img/favicon.ico',
|
favicon: 'img/favicon.ico',
|
||||||
url: 'https://santaspeen.ru',
|
url: process.env.SITE_URL,
|
||||||
baseUrl: '/',
|
baseUrl: '/',
|
||||||
organizationName: 'santaspeen',
|
organizationName: process.env.SITE_ORANIZATION_NAME,
|
||||||
projectName: 'santaspeen.ru',
|
projectName: process.env.SITE_PROJECT_NAME,
|
||||||
trailingSlash: false,
|
trailingSlash: false,
|
||||||
deploymentBranch: 'gh-pages',
|
|
||||||
onBrokenLinks: 'throw',
|
onBrokenLinks: 'throw',
|
||||||
onBrokenMarkdownLinks: 'warn',
|
onBrokenMarkdownLinks: 'warn',
|
||||||
i18n: {
|
i18n: {
|
||||||
@ -51,10 +50,10 @@ const config = {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
// gtag: {
|
gtag: {
|
||||||
// trackingID: process.env.GOOGLE_ANALYTICS_TAG_ID,
|
trackingID: process.env.COUNTER_GOOGLE,
|
||||||
// anonymizeIP: true,
|
anonymizeIP: true,
|
||||||
// },
|
},
|
||||||
theme: {
|
theme: {
|
||||||
customCss: require.resolve('./src/css/custom.css'),
|
customCss: require.resolve('./src/css/custom.css'),
|
||||||
},
|
},
|
||||||
@ -92,12 +91,6 @@ const config = {
|
|||||||
style: 'dark',
|
style: 'dark',
|
||||||
copyright: `Copyright © ${new Date().getFullYear()} SantaSpeen`,
|
copyright: `Copyright © ${new Date().getFullYear()} SantaSpeen`,
|
||||||
},
|
},
|
||||||
// algolia: {
|
|
||||||
// appId: process.env.ALGOLIA_APP_ID,
|
|
||||||
// apiKey: process.env.ALGOLIA_API_KEY,
|
|
||||||
// indexName: process.env.ALGOLIA_INDEX_NAME,
|
|
||||||
// searchParameters: {},
|
|
||||||
// },
|
|
||||||
prism: {
|
prism: {
|
||||||
additionalLanguages: ['bash', 'diff', 'json'],
|
additionalLanguages: ['bash', 'diff', 'json'],
|
||||||
darkTheme: darkTheme,
|
darkTheme: darkTheme,
|
||||||
@ -108,6 +101,12 @@ const config = {
|
|||||||
disableSwitch: false,
|
disableSwitch: false,
|
||||||
respectPrefersColorScheme: false,
|
respectPrefersColorScheme: false,
|
||||||
},
|
},
|
||||||
|
algolia: {
|
||||||
|
appId: process.env.ALGOLIA_APP_ID,
|
||||||
|
apiKey: process.env.ALGOLIA_API_KEY,
|
||||||
|
indexName: process.env.ALGOLIA_INDEX_NAME,
|
||||||
|
searchParameters: {},
|
||||||
|
},
|
||||||
}),
|
}),
|
||||||
plugins: [
|
plugins: [
|
||||||
[
|
[
|
||||||
@ -115,6 +114,9 @@ const config = {
|
|||||||
/** @type {import('docusaurus-plugin-sass').Options} */
|
/** @type {import('docusaurus-plugin-sass').Options} */
|
||||||
{}
|
{}
|
||||||
],
|
],
|
||||||
|
['docusaurus-plugin-yandex-metrica', {
|
||||||
|
counterID: process.env.COUNTER_YANDEX,
|
||||||
|
}],
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -5,19 +5,26 @@ import Giscus from "@giscus/react";
|
|||||||
|
|
||||||
export default function BlogPostItemWrapper(props) {
|
export default function BlogPostItemWrapper(props) {
|
||||||
const { isBlogPostPage } = useBlogPost();
|
const { isBlogPostPage } = useBlogPost();
|
||||||
|
|
||||||
if (!isBlogPostPage) {
|
if (!isBlogPostPage) {
|
||||||
return <BlogPostItem {...props} />;
|
return <BlogPostItem {...props} />;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const repo = "SantaSpeen/santaspeen.ru-blog"
|
||||||
|
const repoId = "R_kgDOK6Fd_Q"
|
||||||
|
const category = "General"
|
||||||
|
const categoryId = "DIC_kwDOK6Fd_c4Cbwpe"
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<BlogPostItem {...props} />
|
<BlogPostItem {...props} />
|
||||||
{(
|
{(
|
||||||
<div className="docusaurus-blog-comments">
|
<div className="docusaurus-blog-comments">
|
||||||
<Giscus
|
<Giscus
|
||||||
repo="SantaSpeen/santaspeen.ru-blog"
|
repo={repo}
|
||||||
repoId="R_kgDOK6Fd_Q"
|
repoId={repoId}
|
||||||
category="General"
|
category={category}
|
||||||
categoryId="DIC_kwDOK6Fd_c4Cbwpe"
|
categoryId={categoryId}
|
||||||
mapping="pathname"
|
mapping="pathname"
|
||||||
reactionsEnabled="1"
|
reactionsEnabled="1"
|
||||||
emitMetadata="0"
|
emitMetadata="0"
|
||||||
@ -30,4 +37,4 @@ export default function BlogPostItemWrapper(props) {
|
|||||||
)}
|
)}
|
||||||
</>
|
</>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user