summaryrefslogtreecommitdiffstats
path: root/src/components/Comment
diff options
context:
space:
mode:
authorArmand Philippot <git@armandphilippot.com>2022-01-29 23:38:13 +0100
committerArmand Philippot <git@armandphilippot.com>2022-01-29 23:38:13 +0100
commit82d310403c4bb09bc2f0a204b6374934a10cf348 (patch)
tree488e93e373a7d9215531bb8fcfc37bcbb290d0fa /src/components/Comment
parentf49dfba86b9ac745ddc374ee0f02f03d7e81d872 (diff)
refactor(config): move config from config dir to utils
Diffstat (limited to 'src/components/Comment')
-rw-r--r--src/components/Comment/Comment.tsx10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/components/Comment/Comment.tsx b/src/components/Comment/Comment.tsx
index e95a378..4835f8c 100644
--- a/src/components/Comment/Comment.tsx
+++ b/src/components/Comment/Comment.tsx
@@ -1,7 +1,7 @@
import { Button } from '@components/Buttons';
import CommentForm from '@components/CommentForm/CommentForm';
-import { config } from '@config/website';
import { Comment as CommentData } from '@ts/types/comments';
+import { settings } from '@utils/config';
import { getFormattedDate } from '@utils/helpers/format';
import Head from 'next/head';
import Image from 'next/image';
@@ -23,7 +23,7 @@ const Comment = ({
}) => {
const intl = useIntl();
const router = useRouter();
- const locale = router.locale ? router.locale : config.locales.defaultLocale;
+ const locale = router.locale ? router.locale : settings.locales.defaultLocale;
const [isReply, setIsReply] = useState<boolean>(false);
const firstFieldRef = useRef<HTMLInputElement>(null);
@@ -146,12 +146,12 @@ const Comment = ({
const schemaJsonLd: WithContext<CommentSchema> = {
'@context': 'https://schema.org',
- '@id': `${config.url}/#comment-${comment.commentId}`,
+ '@id': `${settings.url}/#comment-${comment.commentId}`,
'@type': 'Comment',
parentItem: isNested
- ? { '@id': `${config.url}/#comment-${comment.parentDatabaseId}` }
+ ? { '@id': `${settings.url}/#comment-${comment.parentDatabaseId}` }
: undefined,
- about: { '@type': 'Article', '@id': `${config.url}/#article` },
+ about: { '@type': 'Article', '@id': `${settings.url}/#article` },
author: {
'@type': 'Person',
name: comment.author.name,