comments-section-react
v1.4.2-stable
Published
React component to render a comments section using commentssection.site
Downloads
3
Readme
A React component to render a comments section using commentssection.site. This component allows you to easily embed a comments thread in your React application.
Installation
Install the component via npm:
npm install comments-section-react
Or via Yarn:
yarn add comments-section-react
Usage
To use the CommentsSection
component, you need to obtain a threadId
from the commentssection.site dashboard. Follow these steps:
- Create a New Thread: Go to the commentssection.site dashboard and create a new thread.
- Get the
threadId
: After creating the thread, you will receive athreadId
which you will use in the component.
Example
Here is an example of how to use the CommentsSection
component in your React application:
import React from 'react';
import CommentsSection from 'comments-section-react';
const THREAD_ID = 'your-thread-id'; // Replace with your actual threadId
const App = () => (
<div>
<h1>Comments Section</h1>
<CommentsSection threadId={THREAD_ID} />
</div>
);
export default App;
Props
threadId
(string): The ID of the thread. This ID is provided to you in the dashboard under the thread's section.
License
This project is licensed under the ISC License.
Support
For any questions or support, please contact [email protected]. Opening a GitHub issue is also welcome. For more detailed information, you can refer to the documentation.