benpetsch / react-feedback-dialog

A react user feedback dialog + screenshot + canvas highlighting

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

react-feedback-dialog

A react user feedback dialog component. Enables screenshots and canvas highlighting.

NPM JavaScript Style Guide

Why

To make collecting feedback more easy.

What

Fast feedback, including screenshot, description and sys specs for your webapp.

Install

npm install --save react-feedback-dialog

or

yarn add react-feedback-dialog

Usage

import React, { Component, useState } from 'react';
import FeedbackDialog from 'react-feedback-dialog';

const publishConfig = {
  method: 'http', // one of 'http' or 'mail'
  httpConfig: {
    // [optional] only required for method: 'http'
    destination: 'http://httpbin.org/post'
  }
};

class Example extends Component {
  const [active, setActive] = useState(false);

  render() {
    return (
      <div>
        <button
          onClick={() => setActive(!active)}
        >Give Feedback</button>

        <Index
          publishConfig={publishConfig}
          active={active}
          onClose={() => setActive(!active)}
        />
      </div>
    );
  }
}

License

MIT © Benedikt Schmeitz

About

A react user feedback dialog + screenshot + canvas highlighting

License:MIT License


Languages

Language:JavaScript 100.0%