Skip to content

Commit

Permalink
Change storybook config to typescript, simplify
Browse files Browse the repository at this point in the history
  • Loading branch information
Gregory Joseph committed Dec 9, 2024
1 parent 998b343 commit 2611332
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 32 deletions.
32 changes: 0 additions & 32 deletions tichu-clients/packages/tichu-web/.storybook/main.js

This file was deleted.

31 changes: 31 additions & 0 deletions tichu-clients/packages/tichu-web/.storybook/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
import type { StorybookConfig } from "@storybook/react-vite";

const config: StorybookConfig = {
framework: {
name: "@storybook/react-vite",
options: {},
},
stories: ["../src/**/*.@(mdx|stories.@(ts|tsx|js|jsx))"],

addons: [
"@storybook/addon-links",
"@storybook/addon-essentials",
"@storybook/addon-storysource",
"@chromatic-com/storybook",
],
staticDirs: ["../public"],
typescript: {
// type-check stories during Storybook build
check: true,
reactDocgen: "react-docgen-typescript",
},

docs: {},

async viteFinal(config, options) {
// we'll likely need a way to exclude websocket ("ws") like we did with webpack/craco!?
return config;
},
};

export default config;

0 comments on commit 2611332

Please sign in to comment.