Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"changes": [
{
"packageName": "@rushstack/heft-storybook-plugin",
"comment": "add option to control whether to pass --quiet flag",
"type": "minor"
}
],
"packageName": "@rushstack/heft-storybook-plugin"
}
8 changes: 7 additions & 1 deletion heft-plugins/heft-storybook-plugin/src/StorybookPlugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,12 @@ export interface IStorybookPluginOptions {
* Specifies whether to capture the webpack stats for the storybook build by adding the `--webpack-stats-json` CLI flag.
*/
captureWebpackStats?: boolean;
/**
* Specifies whether to run storybook in quiet mode (--quiet).
*
* @defaultValue `true`
*/
quiet?: boolean;
}

interface IRunStorybookOptions extends IPrepareStorybookOptions {
Expand Down Expand Up @@ -487,7 +493,7 @@ export default class StorybookPlugin implements IHeftTaskPlugin<IStorybookPlugin
storybookArgs.push('--webpack-stats-json');
}

if (!verbose) {
if (options.quiet !== false && !verbose) {
storybookArgs.push('--quiet');
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@
"title": "Specifies whether to capture the webpack stats for storybook build.",
"description": "If this is true, then it will capture the webpack stats for storybook build. Defaults to false.",
"type": "boolean"
},
"quiet": {
"title": "Specifies whether to run storybook in quiet mode (--quiet).",
"description": "If this is true, then it will run storybook in quiet mode. Defaults to true.",
"type": "boolean"
}
}
}