# @types/storybook__addon-info

> TypeScript definitions for @storybook/addon-info

Latest version **5.2.9** (published 2025-11-14) · MIT license · 0 weekly downloads

## Install

```sh
npm install @types/storybook__addon-info
pnpm add @types/storybook__addon-info
yarn add @types/storybook__addon-info
bun add @types/storybook__addon-info
```

## Health

**Score 65/100 (B)** — status: stable.

Positive: has types; no vulnerabilities; high maintenance score; popular repo; extremely popular.

Warnings: low downloads; no esm support.

## Facts

| | |
|---|---|
| Version | 5.2.9 |
| Published | 2025-11-14 |
| First published | 2017-10-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 4 |
| Unpacked size | 8.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51449 |
| Maintainers | types |

## Links

- npm: https://www.npmjs.com/package/@types/storybook__addon-info
- Repository: https://github.com/DefinitelyTyped/DefinitelyTyped
- Homepage: https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/storybook__addon-info
- npm.io page: https://npm.io/package/@types/storybook__addon-info

## Dependencies (4)

- [@types/react](https://npm.io/package/@types/react.md) *
- [@storybook/csf](https://npm.io/package/@storybook/csf.md) 0.0.2--canary.4566f4d.1
- [@storybook/react](https://npm.io/package/@storybook/react.md) ^6.5.9
- [@storybook/addons](https://npm.io/package/@storybook/addons.md) ^6.5.9

## Recent versions

- 5.2.9 (latest) — 2025-11-14
- 5.2.8 (ts4.5) — 2023-11-07
- 5.2.5 (ts4.0) — 2022-07-26
- 5.2.4 (ts3.6) — 2021-07-02
- 5.2.3 (ts3.2) — 2020-10-16
- 5.2.1 (ts3.1) — 2019-11-22
- 4.1.2 (ts2.8) — 2019-06-05
- 3.4.0 (ts2.6) — 2018-08-02
- 3.2.1 (ts2.4) — 2017-11-14
- 5.2.7 — 2023-10-18
- 5.2.6 — 2023-09-25
- 5.2.2 — 2020-09-26
- 5.2.0 — 2019-11-18
- 4.1.1 — 2019-03-11
- 4.1.0 — 2019-02-22
- … 7 more at https://npm.io/package/@types/storybook__addon-info/versions

## README

# Installation
> `npm install --save @types/storybook__addon-info`

# Summary
This package contains type definitions for @storybook/addon-info (https://github.com/storybookjs/storybook).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/storybook__addon-info.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/storybook__addon-info/index.d.ts)
````ts
import { DecoratorFunction, Parameters, StoryApi, StoryFn } from "@storybook/addons";
import { StoryContext } from "@storybook/csf/dist/story";
import { ComponentType, ReactElement } from "react";

export interface WrapStoryProps {
    storyFn?: StoryFn | undefined;
    context?: object | undefined;
    options?: object | undefined;
}

export interface TableComponentOptionProps {
    propDefinitions: Array<{
        property: string;
        propType: object | string; // TODO: info about what this object is...
        required: boolean;
        description: string;
        defaultValue: any;
    }>;
}

export interface Options {
    text?: string | undefined;
    header?: boolean | undefined;
    inline?: boolean | undefined;
    source?: boolean | undefined;
    propTables?: Array<ComponentType<any>> | false | undefined;
    propTablesExclude?: Array<ComponentType<any>> | undefined;
    styles?: object | undefined;
    components?: {
        [key: string]: ComponentType<any>;
    } | undefined;
    /**
     * @deprecated "marksyConf" option has been renamed to "components"
     */
    marksyConf?: object | undefined;
    maxPropsIntoLine?: number | undefined;
    maxPropObjectKeys?: number | undefined;
    maxPropArrayLength?: number | undefined;
    maxPropStringLength?: number | undefined;
    TableComponent?: ComponentType<TableComponentOptionProps> | undefined;
    excludedPropTypes?: string[] | undefined;
}

export function withInfo<A = unknown>(
    story: StoryFn<A>,
    context: StoryContext<{ component: any; storyResult: A }>,
): ReturnType<DecoratorFunction<A>>;

// Legacy, but supported
/**
 * @deprecated withInfo wrapper is deprecated, use the info parameter globally or on each story
 */
export function withInfo(
    textOrOptions?: string | Options,
): (storyFn: StoryFn) => (context?: object) => ReactElement<WrapStoryProps>;

/**
 * @deprecated setDefaults is deprecated. Instead, you can pass options into withInfo(options) directly, or use the info parameter.
 */
export function setDefaults(newDefaults: Options): Options;

declare module "@storybook/addons" {
    interface ClientStoryApi<StoryFnReturnType = unknown> {
        storiesOf(kind: string, module: NodeJS.Module): StoryApi<StoryFnReturnType>;
        addParameters(parameter: Parameters & { info: Options }): StoryApi<StoryFnReturnType>;
        addDecorator(decorator: DecoratorFunction<StoryFnReturnType>): StoryApi<StoryFnReturnType>;
    }
}

````

### Additional Details
 * Last updated: Fri, 14 Nov 2025 18:02:08 GMT
 * Dependencies: [@storybook/addons](https://npmjs.com/package/@storybook/addons), [@storybook/csf](https://npmjs.com/package/@storybook/csf), [@storybook/react](https://npmjs.com/package/@storybook/react), [@types/react](https://npmjs.com/package/@types/react)

# Credits
These definitions were written by [Mark Kornblum](https://github.com/mkornblum), [Mattias Wikstrom](https://github.com/fyrkant), and [Kevin Lee](https://github.com/RunningCoderLee).

---
_Source: https://npm.io/package/@types/storybook__addon-info · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
