{ const disqusShortname = post.title c" /> { const disqusShortname = post.title c" /> { const disqusShortname = post.title c"/>

Disqus comments are not loaded using disqus-react

58 Views Asked by At

I have the setup like this:

import { DiscussionEmbed } from "disqus-react"
const DisqusComments = ({ post }) => {
  const disqusShortname = post.title
  const disqusConfig = {
    url: window.location.href,
    identifier: post._id,
    title: post.title
  }
  return (
    <div>
      <DiscussionEmbed
        shortname={disqusShortname}
        config={disqusConfig}
      />
    </div>
  )
}
export default DisqusComments;

Trying to embed like this:

<DisqusComments post={item}></DisqusComments>

Reference: https://coderrocketfuel.com/article/how-to-add-disqus-to-a-react-application

But some how the disqus plugin doesn't load at all. Could not find answers on web hence posting it here

0

There are 0 best solutions below