1.2.4-beta • Published 4 years ago

commento-react v1.2.4-beta

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

commento-react

Warning ⚠ : This package is not ready to be used in production, also the current layout of the application is synchronized for a special internal usecase. Hence, it won't work with a regular commento installation.

Future Releases: The plan is to make this package work cohesively with a regular commento installtion as described on Commento.io

A react based frontend for Commento

Visit Commento.io to know more about how to setup the backend.

NPM JavaScript Style Guide

Install

npm install --save commento-react

Usage

import React from 'react'

import { CommnetoAuthProvider, CommentsPage } from 'commento-react'
import 'commento-react/dist/commento-style.css'
const dummyAuthToken = process.env.REACT_APP_AUTH_TOKEN

const App = () => {
  return (
    <div>
      <CommnetoAuthProvider
        sso={true}
        commentoOrigin={process.env.REACT_APP_COMMENTO_ORIGIN as string}
        ssoToken={dummyAuthToken}
      >
        <CommentsPage pageId='pageID' />
      </CommnetoAuthProvider>
    </div>
  )
}

License

MIT © apoorvHearth