feat(storybook): add docsMode support (#2551)
This commit is contained in:
parent
cbd5d4c426
commit
cd2597066b
@ -6,6 +6,14 @@ Builder properties can be configured in angular.json when defining the builder,
|
|||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
|
|
||||||
|
### docsMode
|
||||||
|
|
||||||
|
Default: `false`
|
||||||
|
|
||||||
|
Type: `boolean`
|
||||||
|
|
||||||
|
Build a documentation-only site using addon-docs.
|
||||||
|
|
||||||
### outputPath
|
### outputPath
|
||||||
|
|
||||||
Type: `string`
|
Type: `string`
|
||||||
|
|||||||
@ -7,6 +7,14 @@ Read more about how to use builders and the CLI here: https://nx.dev/react/guide
|
|||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
|
|
||||||
|
### docsMode
|
||||||
|
|
||||||
|
Default: `false`
|
||||||
|
|
||||||
|
Type: `boolean`
|
||||||
|
|
||||||
|
Build a documentation-only site using addon-docs.
|
||||||
|
|
||||||
### outputPath
|
### outputPath
|
||||||
|
|
||||||
Type: `string`
|
Type: `string`
|
||||||
|
|||||||
@ -7,6 +7,14 @@ Read more about how to use builders and the CLI here: https://nx.dev/web/guides/
|
|||||||
|
|
||||||
## Properties
|
## Properties
|
||||||
|
|
||||||
|
### docsMode
|
||||||
|
|
||||||
|
Default: `false`
|
||||||
|
|
||||||
|
Type: `boolean`
|
||||||
|
|
||||||
|
Build a documentation-only site using addon-docs.
|
||||||
|
|
||||||
### outputPath
|
### outputPath
|
||||||
|
|
||||||
Type: `string`
|
Type: `string`
|
||||||
|
|||||||
@ -27,6 +27,8 @@ export interface StorybookBuilderOptions extends JsonObject {
|
|||||||
uiFramework: string;
|
uiFramework: string;
|
||||||
config: StorybookConfig;
|
config: StorybookConfig;
|
||||||
quiet?: boolean;
|
quiet?: boolean;
|
||||||
|
outputPath?: string;
|
||||||
|
docsMode?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@ -85,8 +87,8 @@ async function storybookOptionMapper(
|
|||||||
configDir: storybookConfig,
|
configDir: storybookConfig,
|
||||||
...frameworkOptions,
|
...frameworkOptions,
|
||||||
frameworkPresets: [...(frameworkOptions.frameworkPresets || [])],
|
frameworkPresets: [...(frameworkOptions.frameworkPresets || [])],
|
||||||
|
watch: false,
|
||||||
watch: false
|
docsMode: builderOptions.docsMode
|
||||||
};
|
};
|
||||||
optionsWithFramework.config;
|
optionsWithFramework.config;
|
||||||
return optionsWithFramework;
|
return optionsWithFramework;
|
||||||
|
|||||||
@ -47,6 +47,11 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
"docsMode": {
|
||||||
|
"type": "boolean",
|
||||||
|
"description": "Build a documentation-only site using addon-docs.",
|
||||||
|
"default": false
|
||||||
|
},
|
||||||
"quiet": {
|
"quiet": {
|
||||||
"type": "boolean",
|
"type": "boolean",
|
||||||
"description": "Suppress verbose build output.",
|
"description": "Suppress verbose build output.",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user