For React

Before you start: You first need to create an account on feedback.farm.

Get your Project id

You can get your project id by going to feedback.farm and select your project.

Install the library

Our package is available on NPM

# Install via NPM
npm install @feedbackfarm/react

Add the widget to your site

Suppose that you have a React website looking like this

// index.jsx
export default function MyPage() {
    return (
        <div>
            <button>Give feedback</Button>
        </div>
    )
}

You then want to wrap your trigger, in this case the button, to the feedback farm widget. You simply need to do like so 👇

// index.jsx
import { FeedbackFarm } from '@feedbackfarm/react';

export default function MyPage() {
    return (
        <div>
            <FeedbackFarm projectId="project_id">
                <button>Give feedback</Button>
            </FeedbackFarm>
        </div>
    )
}

Now when you click the button, you should see the widget.

Advanced option

Now that you have the widget working correctly, the widget support some properties that will allow you to customize it. Here's the available properties.

*required

Last updated