All Projects → disqus → Disqus React

disqus / Disqus React

Licence: mit
A React component for Disqus

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Disqus React

Mouthful
Mouthful is a self-hosted alternative to Disqus
Stars: ✭ 681 (+146.74%)
Mutual labels:  comments, disqus
Laravel Disqus
A simple Disqus platform integration with Laravel.
Stars: ✭ 71 (-74.28%)
Mutual labels:  comments, disqus
hide-comments-everywhere
A browser extension for hiding major commenting systems like Disqus, Livefyre, Facebook plugin, WordPress, YouTube, etc.
Stars: ✭ 27 (-90.22%)
Mutual labels:  disqus, comments
reddit-fetch
A program to fetch some comments/pictures from reddit
Stars: ✭ 50 (-81.88%)
Mutual labels:  comments
Disqus.NET
Disqus API for .NET
Stars: ✭ 13 (-95.29%)
Mutual labels:  disqus
pull-request-comment-branch
A GitHub Action to get the head ref and sha of a pull request comment
Stars: ✭ 21 (-92.39%)
Mutual labels:  comments
disqusjs-proxy-example
Using Now as Disqus API Proxy
Stars: ✭ 15 (-94.57%)
Mutual labels:  disqus
hyde-hyde
A cool theme inspired by spf13's Hyde theme
Stars: ✭ 234 (-15.22%)
Mutual labels:  disqus
Blog-laravel
This is built on Laravel Framework 5.5. This was built for demonstrate purpose.
Stars: ✭ 48 (-82.61%)
Mutual labels:  disqus
threaded-comments
Reddit styled threaded comments using Supabase and Next.js
Stars: ✭ 111 (-59.78%)
Mutual labels:  comments
gatsby-simple-blog
an easily configurable gatsby-starter-blog with overreacted looking and tags, breadcrumbs, disqus, i18n, eslint, algolia supported
Stars: ✭ 48 (-82.61%)
Mutual labels:  disqus
hugo-initio
Hugo Theme port of Initio bootstrap template by GetTemplate
Stars: ✭ 58 (-78.99%)
Mutual labels:  disqus
lazy-load-for-comments
Lazy load WordPress default commenting system.
Stars: ✭ 17 (-93.84%)
Mutual labels:  comments
Ponza
A comment system for static blog
Stars: ✭ 17 (-93.84%)
Mutual labels:  comments
giscus
A comments system powered by GitHub Discussions. 💬 💎
Stars: ✭ 1,448 (+424.64%)
Mutual labels:  comments
Instagram-Giveaways-Winner
Instagram Bot which when given a post url will spam mentions to increase the chances of winning. Win Instagram Giveaways!
Stars: ✭ 95 (-65.58%)
Mutual labels:  comments
js-cleanup
Smart comment and whitespace cleaner for JavaScript-like files
Stars: ✭ 22 (-92.03%)
Mutual labels:  comments
PointingToTheMoon
Super slim Jekyll Theme created for math posts with easy mermaid diagram
Stars: ✭ 49 (-82.25%)
Mutual labels:  comments
VINS-Mono
VINS-Mono中文注释
Stars: ✭ 149 (-46.01%)
Mutual labels:  comments
hugo-dream-plus
🌈 An upgraded version of the Hugo "Dream" theme with tons of new features.
Stars: ✭ 67 (-75.72%)
Mutual labels:  disqus

disqus-react

npm version

A package for integrating Disqus services into React applications.

Installation

Using npm:

$ npm install --save disqus-react

Using yarn:

$ yarn add disqus-react

Usage

DiscussionEmbed

This is the component that will load the main Disqus comments section.

import { DiscussionEmbed } from 'disqus-react';

<DiscussionEmbed
    shortname='example'
    config={
        {
            url: this.props.article.url,
            identifier: this.props.article.id,
            title: this.props.article.title,
            language: 'zh_TW' //e.g. for Traditional Chinese (Taiwan)	
        }
    }
/>

This component is limited to one instance in the DOM at a time and will handle updates to both the config and shortname props and reload appropriately with the new discussion thread.

CommentCount

This component will display the comment count for the Disqus thread associated with the provided config.

import { CommentCount } from 'disqus-react';

<Disqus.CommentCount
    shortname='example'
    config={
        {
            url: this.props.article.url,
            identifier: this.props.article.id,
            title: this.props.article.title,
        }
    }
>
    {/* Placeholder Text */}
    Comments
</Disqus.CommentCount>

Multiple instances of this component can be included on the same page with different config variables (e.g. an article list showing the comment count for each). However, all threads on the site must be under the same primary site shortname. If the component receives a new shortname, all instances will be reset with counts for threads matching the updated site.

CommentEmbed

This component can be used to embed a Disqus comment into your page.

import { CommentEmbed } from 'disqus-react';

<CommentEmbed
    commentId={this.props.article.featuredCommentId}
    showMedia={true}
    showParentComment={true}
    width={420}
    height={320}
/>

Multiple instances of this component may be include on the same page with different commentId variables and does not require that the embedded comment be under the same primary site shortname.

Contributing

If you'd like to contribute to this package feel free to submit a bug report, feature request, or pull request. Though we would ask that you first read through the contributing guidelines.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].