waveterm/.storybook/main.ts
2024-06-13 19:46:31 -07:00

40 lines
950 B
TypeScript

import type { StorybookConfig } from "@storybook/react-vite";
import { UserConfig, mergeConfig } from "vite";
import electronViteConfig from "../electron.vite.config";
const config: StorybookConfig = {
stories: ["../frontend/**/*.mdx", "../frontend/**/*.stories.@(js|jsx|mjs|ts|tsx)"],
addons: [
"@storybook/addon-links",
"@storybook/addon-essentials",
"@chromatic-com/storybook",
"@storybook/addon-interactions",
],
core: {
builder: "@storybook/builder-vite",
},
framework: {
name: "@storybook/react-vite",
options: {},
},
docs: {},
managerHead: (head) => `
${head}
<meta name="robots" content="noindex" />
`,
typescript: {
reactDocgen: "react-docgen-typescript",
},
async viteFinal(config) {
return mergeConfig(config, electronViteConfig.renderer as UserConfig);
},
};
export default config;