| title | core | ||||
|---|---|---|---|---|---|
| sidebar |
|
Parent: main.js|ts configuration
Type:
{
builder?: string | { name: string; options?: BuilderOptions };
channelOptions?: ChannelOptions;
crossOriginIsolated?: boolean;
disableProjectJson?: boolean;
disableTelemetry?: boolean;
disableWebpackDefaults?: boolean;
disableWhatsNewNotifications?: boolean;
enableCrashReports?: boolean;
renderer?: RendererName;
}Configures Storybook's internal features.
Type:
| '@storybook/builder-vite' | '@storybook/builder-webpack5'
| {
name: '@storybook/builder-vite' | '@storybook/builder-webpack5';
options?: BuilderOptions;
}Configures Storybook's builder, Vite or Webpack.
With the new [Framework API](../new-frameworks.mdx), [`framework.options.builder`](./main-config-framework.mdx#optionsbuilder) is now the preferred way to configure the builder.You should only use core.builder.options if you need to configure a builder that is not part of a framework.
{/* prettier-ignore-start */}
{/* prettier-ignore-end */}
Type: ChannelOptions
{
allowDate: boolean;
allowRegExp: boolean;
allowSymbol: boolean;
allowUndefined: boolean;
maxDepth: number;
space: number | undefined;
}Configures the channel used by Storybook to communicate between the manager and preview.
Only two properties are likely to be used:
Type: number
Default: 3
The maximum depth of nested objects to serialize across the channel. Larger values will be slower.
Type: boolean
Enable CORS headings to run document in a "secure context". See SharedArrayBuffer security requirements
This enables these headers in development-mode:
Cross-Origin-Opener-Policy: same-originCross-Origin-Embedder-Policy: require-corp
{/* prettier-ignore-start */}
{/* prettier-ignore-end */}
Type: boolean
Disables the generation of project.json, a file containing Storybook metadata
{/* prettier-ignore-start */}
{/* prettier-ignore-end */}
Type: boolean
Disables Storybook's telemetry collection.
{/* prettier-ignore-start */}
{/* prettier-ignore-end */}
Type: boolean
Disables Storybook's default Webpack configuration.
{/* prettier-ignore-start */}
{/* prettier-ignore-end */}
Type: boolean
Disables the "What's New" notifications in the UI for new Storybook versions and ecosystem updates (e.g., addons, content, etc.).
{/* prettier-ignore-start */}
{/* prettier-ignore-end */}
Type: boolean
Enable crash reports to be sent to Storybook telemetry.
{/* prettier-ignore-start */}
{/* prettier-ignore-end */}
Type: RendererName
{/* TODO: Is this used? Should it be documented? */}