4.2.3 • Published 6 months ago
@types/babel-plugin-react-docgen v4.2.3
Installation
npm install --save @types/babel-plugin-react-docgen
Summary
This package contains type definitions for babel-plugin-react-docgen (https://github.com/storybookjs/babel-plugin-react-docgen).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/babel-plugin-react-docgen.
index.d.ts
// Type definitions for babel-plugin-react-docgen 4.2
// Project: https://github.com/storybookjs/babel-plugin-react-docgen
// Definitions by: Emily Klassen <https://github.com/forivall>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
type BabelPluginObj = any;
// from react-docgen parse.ts
export type Importer = (path: any, name: string) => any;
export type Handler = (documentation: any, path: any, importer: Importer) => void;
export type Resolver = (node: any, parser: any, importer: Importer) => any;
export interface Options {
resolver?:
| 'findAllComponentDefinitions'
| 'findAllExportedComponentDefinitions'
| 'findExportedComponentDefinition'
| Resolver;
handlers?: Array<string | Handler>;
removeMethods?: boolean;
DOC_GEN_COLLECTION_NAME?: string;
}
declare function babelPluginReactDocgen(babelApi: any): BabelPluginObj;
export default babelPluginReactDocgen;
export interface ComponentType {
// DocumentationObject
__docgenInfo: any;
}
Additional Details
- Last updated: Sun, 07 Nov 2021 20:01:26 GMT
- Dependencies: none
- Global values: none
Credits
These definitions were written by Emily Klassen.