Skip to content

v0.20.0

Compare
Choose a tag to compare
@storybook-bot storybook-bot released this 28 Nov 10:07

Release Notes

Refactor: Align with Storybook 8.2 core package layout

This is a structural change that shouldn't really affect you. As long as you have the storybook dependency in your app (which you should), you're good! This change makes it so that the test-runner deduplicates Storybook dependencies, and therefore, slims down your node_modules size.

Feature: Run postVisit on failures (#494)

The test-runner's postVisit hook now runs even if there are failures. This allows you to, for instance, take snapshots on component failures. You can check whether the test has failed via the hasFailure property in the context passed to the hook:

const config: TestRunnerConfig = {
  async postVisit(_page, context) {
    if(context.hasFailure) {
      console.log('problems!')
      // do a snapshot, write a log, or anything you like
    }
  },
}

πŸš€ Enhancement

  • Feature: Run postVisit on failures #494 (@yannbf)
  • Align with Storybook 8.2 core package layout #512 (@yannbf)

πŸ“ Documentation

Authors: 6