• Version 6.4.22
  • Published
  • 55.5 kB
  • 11 dependencies
  • MIT license


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


Core Storybook Router




const DEEPLY_EQUAL: Symbol;
    const Link: {
    ({ to, children, ...rest }: QueryLinkProps): JSX.Element;
    displayName: string;

      variable Location

      const Location: {
      ({ children }: QueryLocationProps): JSX.Element;
      displayName: string;

        variable Match

        const Match: {
        ({ children, path: targetPath, startsWith }: QueryMatchProps): JSX.Element;
        displayName: string;

          variable Route

          const Route: {
          ({ path, children, startsWith, hideOnly }: RouteProps): JSX.Element;
          displayName: string;


            function buildArgsParam

            buildArgsParam: (initialArgs: Args, args: Args) => string;

              function deepDiff

              deepDiff: (value: any, update: any) => any;

                function getMatch

                getMatch: (current: string, target: string, startsWith?: any) => Match | null;

                  function parsePath

                  parsePath: (path: string | undefined) => StoryData;

                    function queryFromLocation

                    queryFromLocation: (location: Partial<Location>) => Query;

                      function queryFromString

                      queryFromString: (s: string) => Query;

                        function stringifyQuery

                        stringifyQuery: (query: Query) => any;

                          function useNavigate

                          useNavigate: () => (
                          to: string | number,
                          options?: ExpandedNavigateOptions
                          ) => void;


                            interface QueryLinkProps

                            interface QueryLinkProps {}

                              property children

                              children: ReactNode;

                                property to

                                to: string;

                                  interface StoryData

                                  interface StoryData {}

                                    property refId

                                    refId?: string;

                                      property storyId

                                      storyId?: string;

                                        property viewMode

                                        viewMode?: string;

                                          Type Aliases

                                          type ExpandedNavigateOptions = NavigateOptions & {
                                          plain?: boolean;

                                            type RenderData

                                            type RenderData = Pick<RouterData, 'location'> & Other;

                                              type RouterData

                                              type RouterData = {
                                              location: Partial<Location>;
                                              navigate: ReturnType<typeof useQueryNavigate>;
                                              } & Other;

                                                Package Files (3)

                                                Dependencies (11)

                                                Dev Dependencies (0)

                                                No dev dependencies.

                                                Peer Dependencies (2)


                                                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/router.

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