Review (beta)

NOTE: Since the Review feature is currently in beta, we're not aiming to migrate any data created previous to the official (non-beta) release to make changes to the feature easier for our development team.

The Widgetbook Cloud Review feature (currently in beta) allows teams to review added, changed or removed components. The Review feature closely relates to reviews known from Pull-Requests. For each Pull-Request, our new widgetbook CLI analyzes the changes to your Widgetbook and creates a review. Members of a frontend-team now can review each changed use-case in isolation and add comments for other team members.

Once all changes from the review are accepted, a developer closes the Pull-Request and the review's status gets updated to merged. For this to work, a webhook to our services is required.

Requirements

To use Widgetbook Cloud Review your setup has to meet the following requirements:

  • Use widgetbook_generator package in version v2.4.1 (no special configuration required).
  • Use widgetbook package in version v2.4.1 (no special configuration required).
  • Use the widgetbook CLI from the widgetbook_cli package. For instructions see Hosting.
  • Setup a GitHub webhook

Setup Webhook (GitHub)

A GitHub Webhook allows Widgetbook Cloud to receive information about changes within your repository. Widgetbook Cloud can automatically set the state of a Review to closed or merged when a corresponding Pull-Request is closed or merged. For this to work, you need to configure a webhook. See Setting up a webhook for instructions on how to do this.

Requirements

You need to meet the following requirements to setup a webhook to Widgetbook Cloud:

  • Webhook Secret
  • Payload URL

Obtaining the Webhook Secret

The webhook secret can be obtained by going to the project overview and click the Get secret button within the webhook card.

Setting up the webhook

  1. Go to https://github.com/username/repo-name/settings/hooks. Make sure to replace username and repo-name with your appropriate values.
  2. Click Add webhook
  3. Paste https://api.widgetbook.io/v1/webhooks/github into the Payload URL field.
  4. Set Content type to application/json
  5. Paste your Widgetbook Cloud webhook secret into the Secret field.
  6. Select when to trigger the webhook.
    1. Select Send me everything or
    2. Select Let me select individual events and enable Pull requests. You can disable all other options.