Skip to content
This repository was archived by the owner on Dec 26, 2024. It is now read-only.

Commit 9be0d74

Browse files
authored
Merge pull request #662 from fey/remove-disqus
remove disqus
2 parents 9bb90c3 + 51a7302 commit 9be0d74

File tree

8 files changed

+2
-78
lines changed

8 files changed

+2
-78
lines changed

components/Disqus.jsx

-21
This file was deleted.

components/PostPageInfo.jsx

+1-7
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import { MDXRemote } from 'next-mdx-remote';
55
import { useTranslation } from 'next-i18next';
66

77
import Author from './Author.jsx';
8-
import Disqus from './Disqus.jsx';
98
import Banner from './Banner.jsx';
109
import PostPageNav from './PostPageNav.jsx';
1110
import ExternalLink from './ExternalLink.jsx';
@@ -15,7 +14,7 @@ const components = {
1514
a: ExternalLink,
1615
};
1716

18-
const PostPageInfo = ({ post, disqus }) => {
17+
const PostPageInfo = ({ post }) => {
1918
const { t } = useTranslation('post');
2019

2120
const postImage = post.image ? (
@@ -44,11 +43,6 @@ const PostPageInfo = ({ post, disqus }) => {
4443
</span>
4544
<Author name={post.author} url={post.author_url} />
4645
</div>
47-
<section>
48-
<div id="comments">
49-
<Disqus shortName={disqus.short_name} config={disqus.config} />
50-
</div>
51-
</section>
5246
</div>
5347
</div>
5448
);

data/config.js

-4
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,6 @@ const config = {
1313
logo: '/images/hexlet_logo.png',
1414
favicon: '/assets/images/favicons/favicon-128.png',
1515
author: 'Kirill Mokevnin',
16-
disqus: {
17-
ru: 'hexlet-guides',
18-
en: 'hexlet-guides-en',
19-
},
2016
amp: {
2117
analytics: {
2218
metrikaCounterId: '65474386',

package-lock.json

-16
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@
2323
"@sentry/nextjs": "^7.17.3",
2424
"bootstrap": "^5.1.3",
2525
"date-fns": "^2.29.3",
26-
"disqus-react": "^1.1.3",
2726
"file-loader": "^6.2.0",
2827
"gray-matter": "^4.0.3",
2928
"lodash.capitalize": "^4.2.1",

pages/[name].js

+1-9
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,6 @@ const Post = ({ post, languageMarkup }) => {
1616
return null;
1717
}
1818

19-
const disqus = {
20-
short_name: cfg.disqus[locale],
21-
config: {
22-
language: locale,
23-
title: post.title,
24-
identifier: post.name,
25-
},
26-
};
2719
return (
2820
<DefaultLayout
2921
title={post.title}
@@ -34,7 +26,7 @@ const Post = ({ post, languageMarkup }) => {
3426
>
3527
<LanguageMarkup languageMarkup={languageMarkup} />
3628
<MicrometricArticles post={post} />
37-
<PostPageInfo post={post} disqus={disqus} />
29+
<PostPageInfo post={post} />
3830
</DefaultLayout>
3931
);
4032
};

public/locales/en/common.json

-10
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,5 @@
3636
"title": "Privacy Policy",
3737
"url": "https://hexlet.io/pages/privacy"
3838
}
39-
},
40-
"disqus": {
41-
"noscript": {
42-
"prefix": "Please enable JavaScript to view the",
43-
"link": "comments powered by Disqus."
44-
},
45-
"link": {
46-
"prefix": "comments powered by",
47-
"logo": "Disqus"
48-
}
4939
}
5040
}

public/locales/ru/common.json

-10
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,5 @@
4040
"title": "Политика конфиденциальности",
4141
"url": "https://ru.hexlet.io/pages/privacy"
4242
}
43-
},
44-
"disqus": {
45-
"noscript": {
46-
"prefix": "Please enable JavaScript to view the",
47-
"link": "comments powered by Disqus."
48-
},
49-
"link": {
50-
"prefix": "comments powered by",
51-
"logo": "Disqus"
52-
}
5343
}
5444
}

0 commit comments

Comments
 (0)