0.1.8 • Published 1 year ago

storybook_vitest_addon v0.1.8

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

storybook_vitest_addon

Release

Installation:

yarn add storybook_vitest_addon

Compatibility:

"storybook": "^8.1.5",
"@storybook/react": "8.1.5",
"@storybook/react-vite": "^8.1.5",
"vitest": "^1.1.0"

Description:

Addon meant to display Vitest unit test results in a new Stoybook panel. Developed and tested with React. Simply add it to the addon list in your Storybook config, and then you can use it in any story.

The addon offers minimal visuals for maximum clarity. It needs 2 params: testResults - test results file in json format and testFile - name of the component test file (TypeScript definitions available).

Example usage:

// Button.stories.tsx

import vitestResults from "./unit-test-results.json";
/.../
export default {
  title: "Example/Button",
  component: Button,
  parameters: {
    vitest: {
      testFile: "Button.test.tsx",
      testResults: vitestResults,
    },
  },
};
/.../

npm.io

Also see https://storybook.js.org/addons/storybook_vitest_addon

0.1.8

1 year ago

0.1.7

1 year ago

0.1.5

2 years ago

0.1.0

2 years ago

0.1.2

2 years ago

0.1.1

2 years ago

0.1.3

2 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago