@storybook/angular

  • Version 6.5.12
  • Published
  • 255 kB
  • 36 dependencies
  • MIT license

Install

npm i @storybook/angular
yarn add @storybook/angular
pnpm add @storybook/angular

Overview

Storybook for Angular: Develop Angular Components in isolation with Hot Reloading.

Index

Variables

variable addDecorator

const addDecorator: any;

    variable addParameters

    const addParameters: any;

      variable configure

      const configure: (loader: Loadable, module: NodeModule) => void;

        variable forceReRender

        const forceReRender: () => void;

          variable getStorybook

          const getStorybook: () => IStorybookSection[];

            variable raw

            const raw: () => any;

              variable setAddon

              const setAddon: (addon: any) => void;

                variable storiesOf

                const storiesOf: any;

                  Functions

                  function componentWrapperDecorator

                  componentWrapperDecorator: <TArgs = any>(
                  element: any,
                  props?:
                  | ICollection
                  | ((storyContext: StoryContext<AngularFramework, TArgs>) => ICollection)
                  ) => DecoratorFunction<AngularFramework, TArgs>;

                    function moduleMetadata

                    moduleMetadata: <TArgs = any>(
                    metadata: Partial<NgModuleMetadata>
                    ) => DecoratorFunction<AngularFramework, TArgs>;

                      Interfaces

                      interface IStory

                      interface StoryFnAngularReturnType {}

                        property component

                        component?: any;
                        • Deprecated

                          component story input is deprecated, and will be removed in Storybook 7.0.

                        property moduleMetadata

                        moduleMetadata?: NgModuleMetadata;

                          property props

                          props?: ICollection;

                            property propsMeta

                            propsMeta?: ICollection;
                            • Deprecated

                              propsMeta story input is deprecated, and will be removed in Storybook 7.0.

                            property styles

                            styles?: string[];

                              property template

                              template?: string;

                                property userDefinedTemplate

                                userDefinedTemplate?: boolean;

                                  Type Aliases

                                  type AngularFramework

                                  type AngularFramework = {
                                  component: any;
                                  storyResult: StoryFnAngularReturnType;
                                  };

                                    type Meta

                                    type Meta<TArgs = Args> = ComponentAnnotations<AngularFramework, TArgs>;
                                    • Metadata to configure the stories for a component.

                                      See Also

                                      • [Default export](https://storybook.js.org/docs/formats/component-story-format/#default-export)

                                    type Parameters

                                    type Parameters = DefaultParameters & {
                                    /** Uses legacy angular rendering engine that use dynamic component */
                                    angularLegacyRendering?: boolean;
                                    bootstrapModuleOptions?: unknown;
                                    };

                                      type Story

                                      type Story<TArgs = Args> = StoryFn<TArgs>;
                                      • Story function that represents a CSFv2 component example.

                                        See Also

                                        • [Named Story exports](https://storybook.js.org/docs/formats/component-story-format/#named-story-exports)

                                          NOTE that in Storybook 7.0, this type will be renamed to StoryFn and replaced by the current StoryObj type.

                                      type StoryContext

                                      type StoryContext = DefaultStoryContext<AngularFramework> & {
                                      parameters: Parameters;
                                      };

                                        type StoryFn

                                        type StoryFn<TArgs = Args> = AnnotatedStoryFn<AngularFramework, TArgs>;
                                        • Story function that represents a CSFv2 component example.

                                          See Also

                                          • [Named Story exports](https://storybook.js.org/docs/formats/component-story-format/#named-story-exports)

                                        type StoryObj

                                        type StoryObj<TArgs = Args> = StoryAnnotations<AngularFramework, TArgs>;
                                        • Story function that represents a CSFv3 component example.

                                          See Also

                                          • [Named Story exports](https://storybook.js.org/docs/formats/component-story-format/#named-story-exports)

                                        Namespaces

                                        namespace @storybook/angular/demo

                                        module '@storybook/angular/demo' {}

                                          variable Button

                                          const Button: any;

                                            variable Welcome

                                            const Welcome: any;

                                              Package Files (6)

                                              Dependencies (36)

                                              Dev Dependencies (20)

                                              Peer Dependencies (16)

                                              Badge

                                              To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                              You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@storybook/angular.

                                              • Markdown
                                                [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@storybook/angular)
                                              • HTML
                                                <a href="https://www.jsdocs.io/package/@storybook/angular"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>