Skip to content

Commit

Permalink
Enable feature comments Mess
Browse files Browse the repository at this point in the history
Signed-off-by: Shivank Anchal <anchalshivank99@gmail.com>
  • Loading branch information
anchalshivank committed Sep 12, 2024
1 parent 252a7ae commit 896ae49
Showing 1 changed file with 8 additions and 12 deletions.
20 changes: 8 additions & 12 deletions src/theme/BlogPostItem/index.js
Original file line number Diff line number Diff line change
@@ -1,30 +1,26 @@
import React from 'react'
import React from 'react';
import { DiscussionEmbed } from 'disqus-react'
import BlogPostItem from '@theme-original/BlogPostItem';
import { useBlogPost } from '@docusaurus/theme-common/internal'
import BlogPostItem from '@theme-original/BlogPostItem'

export default function BlogPostItemWrapper(props) {
const { metadata } = useBlogPost()
const { frontMatter, permalink, title } = metadata
const { frontMatter, slug, title } = metadata
const { comments = true } = frontMatter
console.log(metadata)


return (
<>
<BlogPostItem {...props} />
Cool
{comments && (
<DiscussionEmbed
shortname='https-replica-io-dev-1'
shortname='https-replica-io-dev'
config={{
url: permalink,
identifier: permalink,
url: slug,
identifier: slug,
title,
language: 'en_US',
}}
/>
)}
</>
)
}
);
}

0 comments on commit 896ae49

Please sign in to comment.